view doc/posix-functions/opendir.texi @ 15610:de2ecfd7fc4a

New modules 'opendir', 'readdir', 'rewinddir', 'closedir'. * lib/dirent.in.h (struct dirent): New type. (DT_UNKNOWN, DT_FIFO, DT_CHR, DT_DIR, DT_BLK, DT_REG, DT_LNK, DT_SOCK, DT_WHT): New macros. (DIR): New type. (opendir, closedir): Declare only if the module 'opendir' is enabled. (readdir, rewinddir): New declarations. * lib/dirent-private.h: New file. * lib/opendir.c: New file. * lib/readdir.c: New file. * lib/rewinddir.c: New file. * lib/closedir.c: New file. * lib/fchdir.c (rpl_closedir, rpl_opendir): Remove functions. * m4/opendir.m4: New file. * m4/readdir.m4: New file. * m4/rewinddir.m4: New file. * m4/closedir.m4: New file. * m4/fchdir.m4 (gl_FUNC_FCHDIR): Don't set REPLACE_OPENDIR, REPLACE_CLOSEDIR here. * m4/dirent_h.m4 (gl_DIRENT_H): Also check whether closedir, opendir, readdir, rewinddir are declared. (gl_DIRENT_H_DEFAULTS): Initialize GNULIB_OPENDIR, GNULIB_READDIR, GNULIB_REWINDDIR, GNULIB_CLOSEDIR, HAVE_OPENDIR, HAVE_READDIR, HAVE_REWINDDIR, HAVE_CLOSEDIR. * modules/dirent (Makefile.am): Substitute GNULIB_OPENDIR, GNULIB_READDIR, GNULIB_REWINDDIR, GNULIB_CLOSEDIR, HAVE_OPENDIR, HAVE_READDIR, HAVE_REWINDDIR, HAVE_CLOSEDIR. * modules/opendir: New file. * modules/readdir: New file. * modules/rewinddir: New file. * modules/closedir: New file. * doc/posix-functions/opendir.texi: Mention the 'opendir' module. * doc/posix-functions/readdir.texi: Mention the 'readdir' module. * doc/posix-functions/rewinddir.texi: Mention the 'rewinddir' module. * doc/posix-functions/closedir.texi: Mention the 'closedir' module. * NEWS: Mention the 'fchdir' change.
author Bruno Haible <bruno@clisp.org>
date Tue, 13 Sep 2011 01:37:35 +0200
parents 6355dc4626b5
children a07c969138fa
line wrap: on
line source

@node opendir
@section @code{opendir}
@findex opendir

POSIX specification:@* @url{http://www.opengroup.org/onlinepubs/9699919799/functions/opendir.html}

Gnulib module: opendir

Portability problems fixed by Gnulib:
@itemize
@item
This function is missing on some platforms:
MSVC 9.
@end itemize

Portability problems not fixed by Gnulib:
@itemize
@item
On platforms where @code{off_t} is a 32-bit type, this function may not
work correctly on huge directories larger than 2 GB.  Also, on platforms
where @code{ino_t} is a 32-bit type, this function may report inode numbers
incorrectly.  The fix is to use the @code{AC_SYS_LARGEFILE} macro.
@end itemize