diff --git a/src/terminal/sys/unix.rs b/src/terminal/sys/unix.rs index a9e9ec04..e7758264 100644 --- a/src/terminal/sys/unix.rs +++ b/src/terminal/sys/unix.rs @@ -67,7 +67,7 @@ pub(crate) fn window_size() -> io::Result { ws_ypixel: 0, }; - let file = File::open("/dev/tty").map(|file| (FileDesc::new(file.into_raw_fd(), true))); + let file = File::open("/dev/tty").map(|file| FileDesc::new(file.into_raw_fd(), true)); let fd = if let Ok(file) = &file { file.raw_fd() } else { @@ -84,7 +84,7 @@ pub(crate) fn window_size() -> io::Result { #[cfg(not(feature = "libc"))] pub(crate) fn window_size() -> io::Result { - let file = File::open("/dev/tty").map(|file| (FileDesc::Owned(file.into()))); + let file = File::open("/dev/tty").map(|file| FileDesc::Owned(file.into())); let fd = if let Ok(file) = &file { file.as_fd() } else {