(oflags: OFlags)
| 378 | #[cfg(target_pointer_width = "32")] |
| 379 | #[inline] |
| 380 | fn oflags_bits(oflags: OFlags) -> c::c_uint { |
| 381 | let mut bits = oflags.bits(); |
| 382 | // Add `O_LARGEFILE`, unless `O_PATH` is set, as Linux returns `EINVAL` |
| 383 | // when both are set. |
| 384 | if !oflags.contains(OFlags::PATH) { |
| 385 | bits |= O_LARGEFILE; |
| 386 | } |
| 387 | bits |
| 388 | } |
| 389 | |
| 390 | #[cfg(target_pointer_width = "64")] |
| 391 | #[inline] |
no test coverage detected