Commit | Line | Data |
---|---|---|
0a753a76 | 1 | // dirent.h |
2 | ||
3 | // djl | |
4 | // Provide UNIX compatibility | |
5 | ||
6 | #ifndef _INC_DIRENT | |
7 | #define _INC_DIRENT | |
8 | ||
9 | // | |
10 | // NT versions of readdir(), etc | |
11 | // From the MSDOS implementation | |
12 | // | |
13 | ||
14 | // Directory entry size | |
15 | #ifdef DIRSIZ | |
16 | #undef DIRSIZ | |
17 | #endif | |
18 | #define DIRSIZ(rp) (sizeof(struct direct)) | |
19 | ||
20 | // needed to compile directory stuff | |
21 | #define DIRENT direct | |
22 | ||
23 | // structure of a directory entry | |
24 | typedef struct direct | |
25 | { | |
26 | long d_ino; // inode number (not used by MS-DOS) | |
27 | int d_namlen; // Name length | |
28 | char d_name[257]; // file name | |
29 | } _DIRECT; | |
30 | ||
31 | // structure for dir operations | |
32 | typedef struct _dir_struc | |
33 | { | |
34 | char *start; // Starting position | |
35 | char *curr; // Current position | |
36 | long size; // Size of string table | |
37 | long nfiles; // number if filenames in table | |
38 | struct direct dirstr; // Directory structure to return | |
39 | } DIR; | |
40 | ||
c5be433b | 41 | #if 0 /* these have moved to win32iop.h */ |
ce2e26e5 GS |
42 | DIR * win32_opendir(char *filename); |
43 | struct direct * win32_readdir(DIR *dirp); | |
44 | long win32_telldir(DIR *dirp); | |
45 | void win32_seekdir(DIR *dirp,long loc); | |
46 | void win32_rewinddir(DIR *dirp); | |
47 | int win32_closedir(DIR *dirp); | |
c5be433b | 48 | #endif |
0a753a76 | 49 | |
50 | #endif //_INC_DIRENT |