diff options
author | Renzo Davoli <renzo@cs.unibo.it> | 2023-12-10 09:07:52 +0100 |
---|---|---|
committer | Alejandro Colomar <alx@kernel.org> | 2024-01-01 12:38:13 +0100 |
commit | 26cdb3ebb2f6bd5a0c947bcf46e35b7c07759632 (patch) | |
tree | fe2be3294414d3ecb4b6855ac14de70cb392d9cf | |
parent | bfa02bd5d0802c852717fe89c46bf726c56b00a9 (diff) |
faccessat(2), utimensat(2): Document AT_EMPTY_PATH flag
utimensat() and faccessat() support the flag AT_EMPTY_PATH since
Linux 5.8.
(actually Linux 5.8 added faccessat2(): glibc wrapper for faccessat()
uses faccessat2(), and faccessat2() does support AT_EMPTY_PATH).
Reuse the standard text used in many other -at manual pages.
Signed-off-by: Renzo Davoli <renzo@cs.unibo.it>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
-rw-r--r-- | man2/access.2 | 21 | ||||
-rw-r--r-- | man2/utimensat.2 | 25 |
2 files changed, 44 insertions, 2 deletions
diff --git a/man2/access.2 b/man2/access.2 index 95de3815d..2b3e70e34 100644 --- a/man2/access.2 +++ b/man2/access.2 @@ -155,6 +155,27 @@ By default, uses the real IDs (like .BR access ()). .TP +.BR AT_EMPTY_PATH " (since Linux 5.8)" +If +.I pathname +is an empty string, operate on the file referred to by +.I dirfd +(which may have been obtained using the +.BR open (2) +.B O_PATH +flag). +In this case, +.I dirfd +can refer to any type of file, not just a directory. +If +.I dirfd +is +.BR AT_FDCWD , +the call operates on the current working directory. +This flag is Linux-specific; define +.B _GNU_SOURCE +to obtain its definition. +.TP .B AT_SYMLINK_NOFOLLOW If .I pathname diff --git a/man2/utimensat.2 b/man2/utimensat.2 index 495e15cee..d58b4d82e 100644 --- a/man2/utimensat.2 +++ b/man2/utimensat.2 @@ -182,10 +182,31 @@ is ignored. .P The .I flags -field is a bit mask that may be 0, or include the following constant, -defined in +argument is a bit mask created by ORing together zero or more of +the following values defined in .IR <fcntl.h> : .TP +.BR AT_EMPTY_PATH " (since Linux 5.8)" +If +.I pathname +is an empty string, operate on the file referred to by +.I dirfd +(which may have been obtained using the +.BR open (2) +.B O_PATH +flag). +In this case, +.I dirfd +can refer to any type of file, not just a directory. +If +.I dirfd +is +.BR AT_FDCWD , +the call operates on the current working directory. +This flag is Linux-specific; define +.B _GNU_SOURCE +to obtain its definition. +.TP .B AT_SYMLINK_NOFOLLOW If .I pathname |