summaryrefslogtreecommitdiff
path: root/alacritty_terminal/src/tty/windows/conpty.rs
diff options
context:
space:
mode:
Diffstat (limited to 'alacritty_terminal/src/tty/windows/conpty.rs')
-rw-r--r--alacritty_terminal/src/tty/windows/conpty.rs8
1 files changed, 4 insertions, 4 deletions
diff --git a/alacritty_terminal/src/tty/windows/conpty.rs b/alacritty_terminal/src/tty/windows/conpty.rs
index b9748c8b..5469c7fe 100644
--- a/alacritty_terminal/src/tty/windows/conpty.rs
+++ b/alacritty_terminal/src/tty/windows/conpty.rs
@@ -233,12 +233,12 @@ impl OnResize for Conpty {
}
/// Helper to build a COORD from a SizeInfo, returning None in overflow cases.
-fn coord_from_sizeinfo(sizeinfo: &SizeInfo) -> Option<COORD> {
- let cols = sizeinfo.cols().0;
- let lines = sizeinfo.lines().0;
+fn coord_from_sizeinfo(size: &SizeInfo) -> Option<COORD> {
+ let cols = size.cols().0;
+ let lines = size.screen_lines().0;
if cols <= i16::MAX as usize && lines <= i16::MAX as usize {
- Some(COORD { X: sizeinfo.cols().0 as i16, Y: sizeinfo.lines().0 as i16 })
+ Some(COORD { X: cols as i16, Y: lines as i16 })
} else {
None
}