Magellan Linux

Contents of /trunk/mkinitrd-magellan/klibc/usr/include/dirent.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 532 - (show annotations) (download)
Sat Sep 1 22:45:15 2007 UTC (16 years, 9 months ago) by niro
File MIME type: text/plain
File size: 624 byte(s)
-import if magellan mkinitrd; it is a fork of redhats mkinitrd-5.0.8 with all magellan patches and features; deprecates magellan-src/mkinitrd

1 /*
2 * dirent.h
3 */
4
5 #ifndef _DIRENT_H
6 #define _DIRENT_H
7
8 #include <klibc/extern.h>
9 #include <sys/dirent.h>
10
11 struct _IO_dir {
12 int __fd;
13
14 #ifdef __KLIBC_DIRENT_INTERNALS
15 /* These fields for internal use only */
16
17 size_t bytes_left;
18 struct dirent *next;
19 /* Declaring this as an array of struct enforces correct alignment */
20 struct dirent buffer[15]; /* 15 times max dirent size =~ 4K */
21 #endif
22 };
23 typedef struct _IO_dir DIR;
24
25 __extern DIR *opendir(const char *);
26 __extern struct dirent *readdir(DIR *);
27 __extern int closedir(DIR *);
28 static __inline__ int dirfd(DIR * __d)
29 {
30 return __d->__fd;
31 }
32
33 #endif /* _DIRENT_H */