diff options
author | Bryant Mairs <bryant@mai.rs> | 2017-08-23 17:59:34 -0700 |
---|---|---|
committer | Bryant Mairs <bryant@mai.rs> | 2017-08-29 18:47:40 -0700 |
commit | 2d4b13715aa46741c7cd5d2e4461eb0c44f8d424 (patch) | |
tree | acfbb21cff8d9e9ed2393a9af6789c97ec13638a /test/sys | |
parent | 28c5b4a41a45a3ee5ec6c88927388b208f0449c3 (diff) | |
download | nix-2d4b13715aa46741c7cd5d2e4461eb0c44f8d424.zip |
Use upstream libc definitions for fcntl FFI
Diffstat (limited to 'test/sys')
-rw-r--r-- | test/sys/test_termios.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/test/sys/test_termios.rs b/test/sys/test_termios.rs index 2455a4e5..6640c3af 100644 --- a/test/sys/test_termios.rs +++ b/test/sys/test_termios.rs @@ -116,7 +116,7 @@ fn test_local_flags() { // Set the master is in nonblocking mode or reading will never return. let flags = fcntl::fcntl(pty.master, fcntl::F_GETFL).unwrap(); - let new_flags = fcntl::OFlag::from_bits(flags).unwrap() | fcntl::O_NONBLOCK; + let new_flags = fcntl::OFlag::from_bits_truncate(flags) | fcntl::O_NONBLOCK; fcntl::fcntl(pty.master, fcntl::F_SETFL(new_flags)).unwrap(); // Write into the master |