Каталог требований LSB Core 3.1
Требования для функции 'readdir_r'
| Standard | ID | Description |
| SUSv3 | readdir_r.01 | The readdir_r() function shall initialize the dirent structure referenced by entry to represent the directory entry at the current position in the directory stream referred to by dirp, store a pointer to this structure at the location referenced by result, and position the directory stream at the next entry. |
| SUSv3 | readdir_r.02 | The storage pointed to by entry shall be large enough for a dirent with an array of char d_name members containing at least {NAME_MAX}+1 elements. |
| SUSv3 | readdir_r.03 | Upon successful return, the pointer returned at *result shall have the same value as the argument entry. |
| SUSv3 | readdir_r.04 | Upon reaching the end of the directory stream, this pointer shall have the value NULL. |
| SUSv3 | readdir_r.05 | The readdir_r() function shall not return directory entries containing empty names |
| SUSv3 | readdir_r.06 | If a file is removed from or added to the directory after the most recent call to opendir() or rewinddir(), whether a subsequent call to readdir_r() returns an entry for that file is unspecified. |
| SUSv3 | readdir_r.07 | The readdir_r() function may buffer several directory entries per actual read operation; the readdir_r() function shall mark for update the st_atime field of the directory each time the directory is actually read |
| SUSv3 | readdir_r.09 | If successful, the readdir_r() function shall return zero; otherwise, an error number shall be returned to indicate the error. |
| SUSv3 | readdir_r.91 | The readdir_r() function may fail if: |
| SUSv3 | readdir_r.91.01 | [EBADF] The dirp argument does not refer to an open directory stream. |