Re: [PATCH v4 0/3] vfs: Define new syscall umask2 [formerly getumask]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 04/13/16 12:05, Richard W.M. Jones wrote:
v3 -> v4:

  - Rename the syscall: getumask becomes umask2.

  - Add flags parameter, with one flag (UMASK_GET_MASK).

  - Expand the rationale for this change in the first commit message.


It's not possible to read the process umask without also modifying it,
which is what umask(2) does.  A library cannot read umask safely,
especially if the main program might be multithreaded.


I wouldn't say "if"; that is the case when it matters.

I have to say I'm skeptic to the need for umask2() as opposed to getumask(). I would also like to be able to get the umask of another process, which would argue for adding it to /proc anyway.

	-hpa

--
To unsubscribe from this list: send the line "unsubscribe linux-api" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux