Name
umask
Synopsis
umask expr
Sets the umask for the process to
expr
and returns the old one. (The
umask tells Unix which permission bits to disallow when creating a
file.) If expr
is omitted, the function
merely returns the current umask. For example, to ensure that the
“other” bits are turned on and that the “user” bits are turned
off, try something like:
umask((umask( ) & 077) | 7);
Get Perl in a Nutshell, 2nd Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.