Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic

Re^7: invoking umask command in perl

by shmem (Canon)
on Jun 01, 2011 at 19:39 UTC ( #907700=note: print w/replies, xml ) Need Help??

in reply to Re^6: invoking umask command in perl
in thread invoking umask command in perl

By altering a copy, you won't change the original. The perl program gets its environment and bits and settings from the invoking process, and that one (e.g. a root shell) won't change its mind just because perl is twiddling its own copy of the big picture. There are tricks to swap copy and original, but these involve changing system files. And even so, if you change things behind the back of the program which invoked perl, it just won't notice. For an effective and persistent change of umask usually a new process chain is necessary, starting with login(1).

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://907700]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (2)
As of 2016-10-25 03:41 GMT
Find Nodes?
    Voting Booth?
    How many different varieties (color, size, etc) of socks do you have in your sock drawer?

    Results (313 votes). Check out past polls.