]> git.ipfire.org Git - thirdparty/glibc.git/blob - sysdeps/nacl/bits/dirent.h
Update copyright dates with scripts/update-copyrights.
[thirdparty/glibc.git] / sysdeps / nacl / bits / dirent.h
1 /* Directory entry structure `struct dirent'. NaCl version.
2 Copyright (C) 2015-2017 Free Software Foundation, Inc.
3 This file is part of the GNU C Library.
4
5 The GNU C Library is free software; you can redistribute it and/or
6 modify it under the terms of the GNU Lesser General Public
7 License as published by the Free Software Foundation; either
8 version 2.1 of the License, or (at your option) any later version.
9
10 The GNU C Library is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 Lesser General Public License for more details.
14
15 You should have received a copy of the GNU Lesser General Public
16 License along with the GNU C Library; if not, see
17 <http://www.gnu.org/licenses/>. */
18
19 #ifndef _DIRENT_H
20 # error "Never use <bits/dirent.h> directly; include <dirent.h> instead."
21 #endif
22
23 /* Note that __ino_t and __ino64_t are the same type.
24 Likewise __off_t and __off64_t are the same type. */
25
26 struct dirent
27 {
28 __ino_t d_ino; /* File serial number. */
29 __off_t d_off; /* File position of this entry. */
30 unsigned short int d_reclen; /* Length of the whole `struct dirent'. */
31
32 /* Only this member is in the POSIX standard. */
33 char d_name[256]; /* We must not include limits.h! */
34 };
35
36 #ifdef __USE_LARGEFILE64
37 /* This is completely identical to `struct dirent'. */
38 struct dirent64
39 {
40 __ino_t d_ino; /* File serial number. */
41 __off_t d_off; /* File position of this entry. */
42 unsigned short int d_reclen; /* Length of the whole `struct dirent'. */
43
44 /* Only this member is in the POSIX standard. */
45 char d_name[256]; /* We must not include limits.h! */
46 };
47 #endif
48
49 #define d_fileno d_ino /* Backwards compatibility. */
50
51 #define _DIRENT_HAVE_D_RECLEN 1
52 #define _DIRENT_MATCHES_DIRENT64 1