Skip to content

Commit d03c1bf

Browse files
committed
add missing O_* flags
1 parent e22c95d commit d03c1bf

File tree

12 files changed

+26
-3
lines changed

12 files changed

+26
-3
lines changed

src/unix/notbsd/android/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -149,7 +149,7 @@ s! {
149149
}
150150

151151
pub const O_TRUNC: ::c_int = 512;
152-
152+
pub const O_LARGEFILE: ::c_int = 0400000;
153153
pub const O_CLOEXEC: ::c_int = 0x80000;
154154

155155
pub const EBFONT: ::c_int = 59;

src/unix/notbsd/linux/mips/mod.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,10 @@ pub const NCCS: usize = 32;
3333

3434
pub const O_TRUNC: ::c_int = 512;
3535

36+
pub const O_LARGEFILE: ::c_int = 0x2000;
37+
pub const O_NOATIME: ::c_int = 0o1000000;
3638
pub const O_CLOEXEC: ::c_int = 0x80000;
39+
pub const O_PATH: ::c_int = 0o10000000;
3740

3841
pub const EBFONT: ::c_int = 59;
3942
pub const ENOSTR: ::c_int = 60;

src/unix/notbsd/linux/musl/mod.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,8 @@ pub const SFD_CLOEXEC: ::c_int = 0x080000;
9292
pub const NCCS: usize = 32;
9393

9494
pub const O_TRUNC: ::c_int = 512;
95-
95+
pub const O_NOATIME: ::c_int = 0o1000000;
96+
pub const O_LARGEFILE: ::c_int = 0o0100000;
9697
pub const O_CLOEXEC: ::c_int = 0x80000;
9798

9899
pub const EBFONT: ::c_int = 59;

src/unix/notbsd/linux/other/b32/arm.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,7 @@ s! {
7575
pub const O_DIRECT: ::c_int = 0x10000;
7676
pub const O_DIRECTORY: ::c_int = 0x4000;
7777
pub const O_NOFOLLOW: ::c_int = 0x8000;
78+
pub const O_LARGEFILE: ::c_int = 0o400000;
7879

7980
pub const MAP_LOCKED: ::c_int = 0x02000;
8081
pub const MAP_NORESERVE: ::c_int = 0x04000;

src/unix/notbsd/linux/other/b32/mod.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,8 @@ pub const O_SYNC: ::c_int = 1052672;
7979
pub const O_RSYNC: ::c_int = 1052672;
8080
pub const O_DSYNC: ::c_int = 4096;
8181
pub const O_FSYNC: ::c_int = 0x101000;
82+
pub const O_NOATIME: ::c_int = 0o1000000;
83+
pub const O_PATH: ::c_int = 0o10000000;
8284

8385
pub const MAP_GROWSDOWN: ::c_int = 0x0100;
8486

src/unix/notbsd/linux/other/b32/powerpc.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,7 @@ s! {
7575
pub const O_DIRECT: ::c_int = 0x20000;
7676
pub const O_DIRECTORY: ::c_int = 0x4000;
7777
pub const O_NOFOLLOW: ::c_int = 0x8000;
78+
pub const O_LARGEFILE: ::c_int = 0o200000;
7879

7980
pub const MAP_LOCKED: ::c_int = 0x00080;
8081
pub const MAP_NORESERVE: ::c_int = 0x00040;

src/unix/notbsd/linux/other/b32/x86.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -174,6 +174,7 @@ s! {
174174
pub const O_DIRECT: ::c_int = 0x4000;
175175
pub const O_DIRECTORY: ::c_int = 0x10000;
176176
pub const O_NOFOLLOW: ::c_int = 0x20000;
177+
pub const O_LARGEFILE: ::c_int = 0o0100000;
177178

178179
pub const MAP_LOCKED: ::c_int = 0x02000;
179180
pub const MAP_NORESERVE: ::c_int = 0x04000;

src/unix/notbsd/linux/other/b64/aarch64.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,9 @@ pub const O_SYNC: ::c_int = 1052672;
9898
pub const O_RSYNC: ::c_int = 1052672;
9999
pub const O_DSYNC: ::c_int = 4096;
100100
pub const O_FSYNC: ::c_int = 0x101000;
101+
pub const O_LARGEFILE: ::c_int = 0o400000;
102+
pub const O_NOATIME: ::c_int = 0o1000000;
103+
pub const O_PATH: ::c_int = 0o10000000;
101104

102105
pub const MAP_GROWSDOWN: ::c_int = 0x0100;
103106

src/unix/notbsd/linux/other/b64/powerpc64.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -96,6 +96,9 @@ pub const O_SYNC: ::c_int = 1052672;
9696
pub const O_RSYNC: ::c_int = 1052672;
9797
pub const O_DSYNC: ::c_int = 4096;
9898
pub const O_FSYNC: ::c_int = 0x101000;
99+
pub const O_LARGEFILE: ::c_int = 0o200000;
100+
pub const O_NOATIME: ::c_int = 0o1000000;
101+
pub const O_PATH: ::c_int = 0o10000000;
99102

100103
pub const MAP_GROWSDOWN: ::c_int = 0x0100;
101104

src/unix/notbsd/linux/other/b64/sparc64.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,9 @@ pub const O_SYNC: ::c_int = 0x802000;
9898
pub const O_RSYNC: ::c_int = 0x802000;
9999
pub const O_DSYNC: ::c_int = 0x2000;
100100
pub const O_FSYNC: ::c_int = 0x802000;
101+
pub const O_LARGEFILE: ::c_int = 0x40000;
102+
pub const O_NOATIME: ::c_int = 0x200000;
103+
pub const O_PATH: ::c_int = 0x1000000;
101104

102105
pub const MAP_GROWSDOWN: ::c_int = 0x0200;
103106

src/unix/notbsd/linux/other/b64/x86_64.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -199,6 +199,9 @@ pub const O_SYNC: ::c_int = 1052672;
199199
pub const O_RSYNC: ::c_int = 1052672;
200200
pub const O_DSYNC: ::c_int = 4096;
201201
pub const O_FSYNC: ::c_int = 0x101000;
202+
pub const O_LARGEFILE: ::c_int = 0;
203+
pub const O_NOATIME: ::c_int = 0o1000000;
204+
pub const O_PATH: ::c_int = 0o10000000;
202205

203206
pub const MAP_GROWSDOWN: ::c_int = 0x0100;
204207

src/unix/notbsd/linux/s390x.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -279,8 +279,10 @@ pub const SFD_CLOEXEC: ::c_int = 0x080000;
279279
pub const NCCS: usize = 32;
280280

281281
pub const O_TRUNC: ::c_int = 512;
282-
282+
pub const O_LARGEFILE: ::c_int = 0o0100000;
283+
pub const O_NOATIME: ::c_int = 0o1000000;
283284
pub const O_CLOEXEC: ::c_int = 0x80000;
285+
pub const O_PATH: ::c_int = 0o10000000;
284286

285287
pub const EBFONT: ::c_int = 59;
286288
pub const ENOSTR: ::c_int = 60;

0 commit comments

Comments
 (0)