Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Get rid of a few warnings during compilation of tests #401

Merged
merged 1 commit into from
Aug 16, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions test/test_mount.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ mod test_mount {
use std::os::unix::fs::PermissionsExt;
use std::process::{self, Command};

use libc::{self, EACCES, EROFS};
use libc::{EACCES, EROFS};

use nix::mount::{mount, umount, MsFlags, MS_BIND, MS_RDONLY, MS_NOEXEC};
use nix::sched::{unshare, CLONE_NEWNS, CLONE_NEWUSER};
Expand Down Expand Up @@ -179,8 +179,8 @@ exit 23";
let mut handle = stderr.lock();
writeln!(handle,
"unshare failed: {}. Are unprivileged user namespaces available?",
e);
writeln!(handle, "mount is not being tested");
e).unwrap();
writeln!(handle, "mount is not being tested").unwrap();
// Exit with success because not all systems support unprivileged user namespaces, and
// that's not what we're testing for.
process::exit(0);
Expand Down
3 changes: 2 additions & 1 deletion test/test_signalfd.rs
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
extern crate nix;

#[cfg(feature = "signalfd")]

use nix::sys::signalfd::SignalFd;
#[cfg(feature = "signalfd")]
use nix::sys::signal;
#[cfg(feature = "signalfd")]
use nix::unistd;

#[cfg(feature = "signalfd")]
Expand Down