diff options
| author | Florian Hahn <flo@fhahn.com> | 2015-12-18 13:29:49 +0100 | 
|---|---|---|
| committer | Florian Hahn <flo@fhahn.com> | 2015-12-29 16:07:01 +0100 | 
| commit | e27cbeff370897b8450caa204c08049651a10c13 (patch) | |
| tree | 471ed007f694634c94b22bfcc5ff4aa2bcc8be16 /src/libstd/sys/unix/process.rs | |
| parent | 27a1834ce522e3ec7fe4726b1661de16ee30c503 (diff) | |
| download | rust-e27cbeff370897b8450caa204c08049651a10c13.tar.gz rust-e27cbeff370897b8450caa204c08049651a10c13.zip | |
Fix warnings when compiling stdlib with --test
Diffstat (limited to 'src/libstd/sys/unix/process.rs')
| -rw-r--r-- | src/libstd/sys/unix/process.rs | 5 | 
1 files changed, 3 insertions, 2 deletions
| diff --git a/src/libstd/sys/unix/process.rs b/src/libstd/sys/unix/process.rs index 407fcb0a1b8..495f45f5c7e 100644 --- a/src/libstd/sys/unix/process.rs +++ b/src/libstd/sys/unix/process.rs @@ -462,8 +462,7 @@ mod tests { use mem; use ptr; use libc; - use slice; - use sys::{self, cvt, pipe}; + use sys::{self, cvt}; macro_rules! t { ($e:expr) => { @@ -482,6 +481,8 @@ mod tests { #[cfg(target_os = "android")] unsafe fn sigaddset(set: *mut libc::sigset_t, signum: libc::c_int) -> libc::c_int { + use slice; + let raw = slice::from_raw_parts_mut(set as *mut u8, mem::size_of::<libc::sigset_t>()); let bit = (signum - 1) as usize; raw[bit / 8] |= 1 << (bit % 8); | 
