Skip to content
Snippets Groups Projects
Commit 6fa612fc authored by bors's avatar bors
Browse files

Auto merge of #905 - wfraser:dt_unknown, r=alexcrichton

add DT_UNKNOWN

The `d_type` field of `struct dirent` can be `DT_UNKNOWN` if a
filesystem doesn't support returning the file type in directory entries.
Linux's readdir(3) man page, for example, says: "Currently, only some
filesystems [...] have full support for returning the file type in
d_type. All applications must properly handle a return of DT_UNKNOWN."
parents 5e290c57 1ada396b
No related branches found
No related tags found
No related merge requests found
......@@ -190,6 +190,7 @@ pub const SIG_DFL: sighandler_t = 0 as sighandler_t;
pub const SIG_IGN: sighandler_t = 1 as sighandler_t;
pub const SIG_ERR: sighandler_t = !0 as sighandler_t;
pub const DT_UNKNOWN: u8 = 0;
pub const DT_FIFO: u8 = 1;
pub const DT_CHR: u8 = 2;
pub const DT_DIR: u8 = 4;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment