Re: [mp2] [bug?] %ENV changes not propagated to qx() and to C-library
> The docs seem to suggest that that changes to %ENV should work fine:[color=blue]
>> mod_perl passes (exports) the following shell environment variables[/color]
> (if they are set) :[color=green]
>> * PATH - Executables search path.
>> * TZ - Time Zone.
>> Any of these environment variables can be accessed via %ENV[/color][/color]
You can *access* them, but if you change them, they will not be
synchronized with the C environment. You have to use Env::C to work
around that. MP2 unties the perl %ENV hash from the C environment
during the request, so any changes you make to %ENV during the request
will never be seen by anything written in C unless you manually copy it
over with something like Env::C.
IMO, it would be a lot easier if we could make the "untie %ENV"
behavior optional with a PerlSwitches configuration directive or
something. If you are running a non-threaded perl on a prefork MPM, I
really do not see the harm in leaving %ENV tied to the C environment.
Maybe I'll try to whip up a patch if I can figure it out :).