diff options
| author | Manish Goregaokar <manishsmail@gmail.com> | 2015-02-27 11:43:09 +0530 |
|---|---|---|
| committer | Manish Goregaokar <manishsmail@gmail.com> | 2015-02-27 20:37:39 +0530 |
| commit | 487ee79e3fb391fc97ea8c9c618eb7780a5dee2d (patch) | |
| tree | c2d74e7c83c31b6128b7bad05f6f185ad50ca3c6 /src/libstd | |
| parent | d9704bdfdb3057ed2a28fcf0dd5c9165ed45189b (diff) | |
| parent | 804c071d8b9cfe4d40df9565558db8a9d87d7775 (diff) | |
| download | rust-487ee79e3fb391fc97ea8c9c618eb7780a5dee2d.tar.gz rust-487ee79e3fb391fc97ea8c9c618eb7780a5dee2d.zip | |
Rollup merge of #22846 - dhuseby:bitrig-cleanup, r=alexcrichton
This patch contains a couple time fixes to make Rust compile on Bitrig again. This does not affect OpenBSD.
Diffstat (limited to 'src/libstd')
| -rw-r--r-- | src/libstd/sys/unix/fs.rs | 15 | ||||
| -rw-r--r-- | src/libstd/sys/unix/process2.rs | 1 |
2 files changed, 1 insertions, 15 deletions
diff --git a/src/libstd/sys/unix/fs.rs b/src/libstd/sys/unix/fs.rs index 1c28d629d40..71b6214460f 100644 --- a/src/libstd/sys/unix/fs.rs +++ b/src/libstd/sys/unix/fs.rs @@ -291,29 +291,14 @@ fn mkstat(stat: &libc::stat) -> FileStat { // FileStat times are in milliseconds fn mktime(secs: u64, nsecs: u64) -> u64 { secs * 1000 + nsecs / 1000000 } - #[cfg(target_os = "bitrig")] - fn ctime(stat: &libc::stat) -> u64 { - mktime(stat.st_ctim.tv_sec as u64, stat.st_ctim.tv_nsec as u64) - } - #[cfg(not(target_os = "bitrig"))] fn ctime(stat: &libc::stat) -> u64 { mktime(stat.st_ctime as u64, stat.st_ctime_nsec as u64) } - #[cfg(target_os = "bitrig")] - fn atime(stat: &libc::stat) -> u64 { - mktime(stat.st_atim.tv_sec as u64, stat.st_atim.tv_nsec as u64) - } - #[cfg(not(target_os = "bitrig"))] fn atime(stat: &libc::stat) -> u64 { mktime(stat.st_atime as u64, stat.st_atime_nsec as u64) } - #[cfg(target_os = "bitrig")] - fn mtime(stat: &libc::stat) -> u64 { - mktime(stat.st_mtim.tv_sec as u64, stat.st_mtim.tv_nsec as u64) - } - #[cfg(not(target_os = "bitrig"))] fn mtime(stat: &libc::stat) -> u64 { mktime(stat.st_mtime as u64, stat.st_mtime_nsec as u64) } diff --git a/src/libstd/sys/unix/process2.rs b/src/libstd/sys/unix/process2.rs index b7a1b002f55..a7d0a864a08 100644 --- a/src/libstd/sys/unix/process2.rs +++ b/src/libstd/sys/unix/process2.rs @@ -439,6 +439,7 @@ fn translate_status(status: c_int) -> ExitStatus { target_os = "ios", target_os = "freebsd", target_os = "dragonfly", + target_os = "bitrig", target_os = "openbsd"))] mod imp { pub fn WIFEXITED(status: i32) -> bool { (status & 0x7f) == 0 } |
