Skip to content

Commit c8daecb

Browse files
committed
Fix Linux ioctl type cast
1 parent cbdcf3e commit c8daecb

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Sources/TauTUI/Terminal/Terminal.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -456,7 +456,7 @@ public final class ProcessTerminal: Terminal {
456456

457457
private func currentTerminalSize() -> (columns: Int, rows: Int) {
458458
var windowSize = winsize()
459-
if ioctl(self.outputFD.rawValue, TIOCGWINSZ, &windowSize) == 0 {
459+
if ioctl(self.outputFD.rawValue, numericCast(TIOCGWINSZ), &windowSize) == 0 {
460460
let cols = Int(windowSize.ws_col)
461461
let rows = Int(windowSize.ws_row)
462462
return (max(cols, 1), max(rows, 1))

0 commit comments

Comments
 (0)