aboutsummaryrefslogtreecommitdiffstats
path: root/com32/include
diff options
context:
space:
mode:
authorH. Peter Anvin <hpa@zytor.com>2010-03-06 14:50:20 -0800
committerH. Peter Anvin <hpa@zytor.com>2010-03-06 14:50:20 -0800
commit8fc99886a6f922a5d4ec105cfd72cd70f5b67d8d (patch)
treec5650de1e583707ac7adf4aa138025037cb60cfe /com32/include
parentc25c83df767519d1a9919dcebda9a58611671cc1 (diff)
downloadsyslinux-8fc99886a6f922a5d4ec105cfd72cd70f5b67d8d.tar.gz
syslinux-8fc99886a6f922a5d4ec105cfd72cd70f5b67d8d.tar.xz
syslinux-8fc99886a6f922a5d4ec105cfd72cd70f5b67d8d.zip
dirent.h: types for the d_type field
Add an enum for the DT_* constants for the d_type field. Signed-off-by: H. Peter Anvin <hpa@zytor.com>
Diffstat (limited to 'com32/include')
-rw-r--r--com32/include/sys/dirent.h14
1 files changed, 12 insertions, 2 deletions
diff --git a/com32/include/sys/dirent.h b/com32/include/sys/dirent.h
index a7f26e45..0a27c66e 100644
--- a/com32/include/sys/dirent.h
+++ b/com32/include/sys/dirent.h
@@ -19,9 +19,19 @@ struct dirent {
char d_name[NAME_MAX + 1];
};
+enum dirent_types {
+ DT_UNKNOWN = 0,
+ DT_FIFO = 1,
+ DT_CHR = 2,
+ DT_DIR = 4,
+ DT_BLK = 6,
+ DT_REG = 8,
+ DT_LNK = 10,
+ DT_SOCK = 12,
+ DT_WHT = 14,
+};
+
struct _DIR_;
typedef struct _DIR_ DIR;
-#define DIR_REC_LEN(name) (12 + strlen(name) + 1 + 3) & ~3
-
#endif /* sys/dirent.h */