readdir.h

来自「功能强大的代理服务器」· C头文件 代码 · 共 34 行

H
34
字号
/* * Structures and types used to implement opendir/readdir/closedir * on Windows 95/NT.*/#include <io.h>#include <stdlib.h>#include <sys/types.h> #ifdef _MSC_VER /* Microsoft C Compiler ONLY *//* struct dirent - same as Unix */struct dirent {    ino_t d_ino;                    /* inode (always 1 in WIN32) */    off_t d_off;                /* offset to this dirent */    unsigned short d_reclen;    /* length of d_name */    char d_name[_MAX_FNAME+1];    /* filename (null terminated) */};/* typedef DIR - not the same as Unix */typedef struct {    long handle;                /* _findfirst/_findnext handle */    short offset;                /* offset into directory */    short finished;             /* 1 if there are not more files */    struct _finddata_t fileinfo;  /* from _findfirst/_findnext */    char *dir;                  /* the dir we are reading */    struct dirent dent;         /* the dirent to return */} DIR;/* Function prototypes */DIR * opendir(const char *);struct dirent * readdir(DIR *);int closedir(DIR *);#endif

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?