Bob Showalter wrote:
You need to set umask to 0 before creating the file.
But don't do that. It's inadvisable to mess with the umask in a
program, IMO.
Why would that be inadvisable?
If the user wants to create files as 666, let him set the umask
before running your program.
If the program, for some reason, requires that a file it creates has
certain permissions, isn't it better to have the program set those
permissions?
One way may be to have umask and/or the permissions set as
configuration variables.
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>