Skip to content
Snippets Groups Projects
Commit c04fd9dc authored by Jeremy Soller's avatar Jeremy Soller
Browse files

Merge branch 'fix-tiocgwinsz-dragonfly' into 'master'

Fix TIOCGWINSZ type mismatch on DragonFly

See merge request redox-os/termion!152
parents ce6b43d0 0837ad5a
No related branches found
No related tags found
No related merge requests found
...@@ -14,7 +14,7 @@ struct TermSize { ...@@ -14,7 +14,7 @@ struct TermSize {
pub fn terminal_size() -> io::Result<(u16, u16)> { pub fn terminal_size() -> io::Result<(u16, u16)> {
unsafe { unsafe {
let mut size: TermSize = mem::zeroed(); let mut size: TermSize = mem::zeroed();
cvt(ioctl(STDOUT_FILENO, TIOCGWINSZ, &mut size as *mut _))?; cvt(ioctl(STDOUT_FILENO, TIOCGWINSZ.into(), &mut size as *mut _))?;
Ok((size.col as u16, size.row as u16)) Ok((size.col as u16, size.row as u16))
} }
} }
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment