]> git.baikalelectronics.ru Git - kernel.git/commit
vfs: make O_PATH file descriptors usable for 'fchdir()'
authorLinus Torvalds <torvalds@linux-foundation.org>
Sat, 7 Jul 2012 17:17:00 +0000 (10:17 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Sun, 8 Jul 2012 00:19:02 +0000 (17:19 -0700)
commit74a4de2f88d8cdf170fab0b24d14a148bba182c4
tree7524ffece22d3a7db3555d1df2e1d1d9370da9dd
parent40bece4d6e5a0783e8ee6baa801ebbf3d0e65e34
vfs: make O_PATH file descriptors usable for 'fchdir()'

We already use them for openat() and friends, but fchdir() also wants to
be able to use O_PATH file descriptors.  This should make it comparable
to the O_SEARCH of Solaris.  In particular, O_PATH allows you to access
(not-quite-open) a directory you don't have read persmission to, only
execute permission.

Noticed during development of multithread support for ksh93.

Reported-by: ольга крыжановская <olga.kryzhanovska@gmail.com>
Cc: Al Viro <viro@zeniv.linux.org.uk>
Cc: stable@kernel.org # O_PATH introduced in 3.0+
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
fs/open.c