Hash :
c36a0f21
Author :
Date :
2024-10-27T17:01:29
doc: Add a module index. * doc/Makefile (undocumented-modules.texi): New rule. (%.info, %.html, %.dvi, %.pdf): Depend on undocumented-modules.texi. (mostlyclean): Remove also *.m and *.tmp. (force): New rule. * doc/*.texi: Add module index entries. * doc/*/*.texi: Likewise.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55
@node access
@subsection @code{access}
@findex access
POSIX specification:@* @url{https://pubs.opengroup.org/onlinepubs/9799919799/functions/access.html}
Gnulib module: access
@mindex access
Portability problems fixed by Gnulib:
@itemize
@item
This function does not support the @code{X_OK} mode on some platforms:
MSVC 14.
@item
This function does not reject trailing slashes on symlinks to non-directories
on some platforms:
Mac OS X 10.5.
@end itemize
Portability problems not fixed by Gnulib:
@itemize
@item
This function uses the effective id instead of the real id on some
platforms:
Cygwin 1.5.x.
@end itemize
Other problems of this function:
@itemize
@item
There is an inherent race between calling this function and performing
some action based on the results; you should think twice before trusting
this function, especially in a set-uid or set-gid program.
@item
This function does not have an option for not following symbolic links
(like @code{stat} versus @code{lstat}). If you need this option, use
the Gnulib module @code{faccessat} with the @code{AT_EACCESS} flag.
@item
On Solaris, for the root user, any file is @code{X_OK} even if the file
does not have the @code{x} permission bit set.
@item
On native Windows, files whose basename does not contain a @samp{.}
cannot be executed through @code{execlp} or @code{execvp}. Nevertheless,
this function may return true for such files.
@item
On Windows, different facilities for executing a program have different
ways of finding an executable file, by trying various suffixes. For
example, @code{execlp} and @code{execvp} search for files with the
suffixes @code{.com}, @code{.exe}, @code{.bat}, @code{.cmd}, when the
file with the given file name does not exist. Whereas @code{cmd.exe}
searches according to the @code{PATHEXT} environment variable. This
function does not perform any search; it merely looks at the file with
the given file name.
@end itemize