File tree Expand file tree Collapse file tree 1 file changed +3
-6
lines changed Expand file tree Collapse file tree 1 file changed +3
-6
lines changed Original file line number Diff line number Diff line change @@ -589,12 +589,9 @@ fn print_terminal_size(
589589 ) ;
590590 }
591591
592- #[ cfg( any( target_os = "linux" , target_os = "redox " ) ) ]
592+ #[ cfg( any( target_os = "linux" , target_os = "android" , target_os = "haiku ") ) ]
593593 {
594- // For some reason the normal nix Termios struct does not expose the line,
595- // so we get the underlying libc::termios struct to get that information.
596- let libc_termios: nix:: libc:: termios = termios. clone ( ) . into ( ) ;
597- let line = libc_termios. c_line ;
594+ let line = termios. line_discipline ;
598595 printer. print ( & translate ! ( "stty-output-line" , "line" => line) ) ;
599596 }
600597 printer. flush ( ) ;
@@ -888,7 +885,7 @@ fn apply_special_setting(
888885 SpecialSetting :: Cols ( n) => size. columns = * n,
889886 SpecialSetting :: Line ( _n) => {
890887 // nix only defines Termios's `line_discipline` field on these platforms
891- #[ cfg( any( target_os = "linux" , target_os = "android" ) ) ]
888+ #[ cfg( any( target_os = "linux" , target_os = "android" , target_os = "haiku" ) ) ]
892889 {
893890 _termios. line_discipline = * _n;
894891 }
You can’t perform that action at this time.
0 commit comments