Skip to content

Commit 117d6b0

Browse files
authored
Merge pull request #3625 from Lilit0x/stat-flags-and-mode-type
Windows `stats::st_mode` and `stat` flags type.
2 parents 91c1297 + b56d275 commit 117d6b0

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

src/windows/mod.rs

+8-8
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ s! {
5959
pub struct stat {
6060
pub st_dev: dev_t,
6161
pub st_ino: ino_t,
62-
pub st_mode: u16,
62+
pub st_mode: c_ushort,
6363
pub st_nlink: ::c_short,
6464
pub st_uid: ::c_short,
6565
pub st_gid: ::c_short,
@@ -142,13 +142,13 @@ pub const _O_OBTAIN_DIR: ::c_int = 0x2000;
142142
pub const O_SEQUENTIAL: ::c_int = 0x0020;
143143
pub const O_RANDOM: ::c_int = 0x0010;
144144

145-
pub const S_IFCHR: ::c_int = 0o2_0000;
146-
pub const S_IFDIR: ::c_int = 0o4_0000;
147-
pub const S_IFREG: ::c_int = 0o10_0000;
148-
pub const S_IFMT: ::c_int = 0o17_0000;
149-
pub const S_IEXEC: ::c_int = 0o0100;
150-
pub const S_IWRITE: ::c_int = 0o0200;
151-
pub const S_IREAD: ::c_int = 0o0400;
145+
pub const S_IFCHR: ::c_ushort = 0o2_0000;
146+
pub const S_IFDIR: ::c_ushort = 0o4_0000;
147+
pub const S_IFREG: ::c_ushort = 0o10_0000;
148+
pub const S_IFMT: ::c_ushort = 0o17_0000;
149+
pub const S_IEXEC: ::c_ushort = 0o0100;
150+
pub const S_IWRITE: ::c_ushort = 0o0200;
151+
pub const S_IREAD: ::c_ushort = 0o0400;
152152

153153
pub const LC_ALL: ::c_int = 0;
154154
pub const LC_COLLATE: ::c_int = 1;

0 commit comments

Comments
 (0)