Bug 17132 - environment variables are not passed to plug-ins
Summary: environment variables are not passed to plug-ins
Status: RESOLVED WONTFIX
Alias: None
Product: WebKit
Classification: Unclassified
Component: Plug-ins (show other bugs)
Version: 528+ (Nightly build)
Hardware: Mac (Intel) OS X 10.5
: P3 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-02-01 07:11 PST by Tom Pelaia II
Modified: 2022-07-01 11:36 PDT (History)
4 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tom Pelaia II 2008-02-01 07:11:07 PST
In previous and currently shipping (v 3.0) versions of Safari, the user's environment variables (both those specified in the user's environment.plist file and (e.g. if launched via Terminal) those defined in the user's shell get passed to plug-ins. The current nightly build of WebKit does not pass environment variables to plug-ins. This breaks a plug-in that we have. It works fine under Safari, but clearly the environment variables are not being passed when run under the current nightly build of WebKit.
Comment 1 Mark Rowe (bdash) 2008-02-01 08:00:00 PST
I'm pretty sure that this an artifact of how WebKitLauncher executes Safari.  It calls execve and passes in the set of environment variables necessary to launch Safari correctly, and makes no effort to inherit any from the current environment.
Comment 2 Mark Rowe (bdash) 2008-02-01 08:03:22 PST
It should be possible to test my theory by bypassing the WebKit.app launcher.  See the section titled "Testing Your Application With Nightly WebKit" at <http://developer.apple.com/opensource/internet/nightlywebkit.html>, and point it at Safari.app.
Comment 3 Tom Pelaia II 2008-02-01 12:27:25 PST
Yes, as suggested the problem goes away when running Safari with the WebKit engine. I confirmed this pointing Safari to the WebKit frameworks and then going to a website that is rendered differently for Safari and WebKit to verify that I am running WebKit. After confirming that I was running WebKit, I setup my environment variables and my plug-in received them correctly. So, I accept the suggested theory from Mark Rowe that the issue is simply an artifact of the WebKitLauncher.

Thank you for the suggestion.
Comment 4 Alexey Proskuryakov 2022-07-01 11:36:10 PDT
Mass closing plug-in bugs, as plug-in support has been removed from WebKit.

Please comment and/or reopen if this still affects WebKit in some way.