getdirentries(3)


NAME

   getdirentries  -  get  directory  entries  in  a filesystem-independent
   format

SYNOPSIS

   #include <dirent.h>

   ssize_t getdirentries(int fd, char *buf, size_t nbytes , off_t *basep);

   Feature Test Macro Requirements for glibc (see feature_test_macros(7)):

   getdirentries():
       Since glibc 2.19:
           _DEFAULT_SOURCE
       Glibc 2.19 and earlier:
           _BSD_SOURCE || _SVID_SOURCE

DESCRIPTION

   Read directory entries from the directory specified by fd into buf.  At
   most  nbytes  are read.  Reading starts at offset *basep, and *basep is
   updated with the new position after reading.

RETURN VALUE

   getdirentries() returns the number of bytes read or zero  when  at  the
   end of the directory.  If an error occurs, -1 is returned, and errno is
   set appropriately.

ERRORS

   See the Linux library source code for details.

ATTRIBUTES

   For  an  explanation  of  the  terms  used   in   this   section,   see
   attributes(7).

   
   Interface        Attribute      Value   
   
   getdirentries()  Thread safety  MT-Safe 
   

CONFORMING TO

   Not  in  POSIX.1.   Present  on the BSDs, and a few other systems.  Use
   opendir(3) and readdir(3) instead.

SEE ALSO

   lseek(2), open(2)

COLOPHON

   This page is part of release 4.09 of the Linux  man-pages  project.   A
   description  of  the project, information about reporting bugs, and the
   latest    version    of    this    page,    can     be     found     at
   https://www.kernel.org/doc/man-pages/.


More Linux Commands

manpages/pam_loginuid.8.html
pam_loginuid(8) - Record user's login uid to the process att
The pam_loginuid module sets the loginuid process attribute for the process that was authenticated. This is necessary for applications to be correctly audited.

manpages/bunzip2.1.html
bunzip2(1) - a block-sorting file compressor, v1.0.6........
bzip2 compresses files using the Burrows-Wheeler block sorting text compression algorithm, and Huffman coding. Compression is generally considerably better than

manpages/get_thread_area.2.html
get_thread_area(2) - Get a Thread Local Storage (TLS) area
get_thread_area() returns an entry in the current threads thread-local storage (TLS) array. The index of the entry corresponds to the value of u_info-&gt;entry_num

blog-dev/commands.html
Important Linux Commands, Concepts, Examples and Explanations
Linux Commands, Concepts and the Command Interpreter. Examples and explanations for I/O, redirection, expansion, pipes, etc. Contains links to Linux manpages.

manpages/mkfs.msdos.8.html
mkfs.msdos(8) - create an MS-DOS file system under Linux....
mkfs.fat is used to create an MS-DOS filesystem under Linux on a device (usually a disk partition). device is the special file corresponding to the device (e.g

manpages/FontCacheGetCacheSettings.3.html
FontCacheGetCacheSettings(3) - X-TrueType font cache extensi
FontCache is an extension that is used by X-TrueType to cache informations about fonts. FontCacheQueryExtension returns True if the FontCache extension is avail

manpages/ovdb_server.8.html
ovdb_server(8) - overview 'helper' server - Linux man page
If the readserver parameter in ovdb.conf is true, ovdb_init will start ovdb_server. ovdb_server opens the overview database, and accesses it on behalf of the nn

manpages/dict.n.html
dict(n) - Manipulate dictionaries - Linux manual page.......
Performs one of several operations on dictionary values or variables containing dictionary values (see the DICTIONARY VALUES section below for a description), d

manpages/v4l.4.html
v4l(4) - video4linux driver (Special - Linux man page)......
v4l is an Xorg driver for video4linux cards. It provides a Xvideo extension port for video overlay. Just add the driver to the module list within the module sec

manpages/etext.3.html
etext(3) - end of program segments - Linux manual page......
The addresses of these symbols indicate the end of various program segments: etext This is the first address past the end of the text segment (the program code)

manpages/mvwinsnstr.3ncurses.html
mvwinsnstr(3ncurses) - insert string before cursor in a curs
These routines insert a character string (as many characters as will fit on the line) before the character under the cursor. All characters to the right of the

manpages/m4.1.html
m4(1) - macro processor (Commands - Linux manual page)......
Process macros in FILEs. If no FILE or if FILE is -, standard input is read. Mandatory or optional arguments to long options are mandatory or optional for short





We can't live, work or learn in freedom unless the software we use is free.