in reply to How is %ENV copied by child processes ?

You have to make your tied %ENV update the underlying %ENV which invokes the "magic" which calls putenv which updates the "real" environment of your process (which is what will be copied to the children).

I don't see any use for appending '---BWUBUBWU' to the end of each environment value so I'll assume this is just a silly example. If you want to tell us what you are really trying to do, then someone will likely show you how to write code that actually does that.

                - tye
  • Comment on Re: How is %ENV copied by child processes ? (untie)

Replies are listed 'Best First'.
Re^2: How is %ENV copied by child processes ?
by Pardus (Pilgrim) on Apr 22, 2003 at 10:52 UTC
    Well, one example would be incorporating the funtionality of the Env module for arrays, but then on an other level.

    An other example would be putting code refs in @PATH which do dynamical lookups. Allowing for the same kind of hooks as supported for @INC and %INC.

    But since I understand this is not a 'perl space' operation but lives in an other dimension of the OS, I just do the same stuff with some quick hacks.
    --
    Jaap Karssenberg || Pardus (Larus)? <pardus@cpan.org>
    >>>> Zoidberg: So many memories, so many strange fluids gushing out of patients' bodies.... <<<<