@@ -395,10 +395,7 @@ pub const O_NDELAY: ::c_int = 0x800;
395
395
pub const NI_MAXHOST : :: size_t = 1025 ;
396
396
397
397
pub const NCCS : usize = 19 ;
398
- pub const TCXONC : :: c_int = 0x540A ;
399
- pub const TCFLSH : :: c_int = 0x540B ;
400
398
pub const TCSBRKP : :: c_int = 0x5425 ;
401
- pub const TCGETS : :: c_int = 0x5401 ;
402
399
pub const TCSANOW : :: c_int = 0 ;
403
400
pub const TCSADRAIN : :: c_int = 0x1 ;
404
401
pub const TCSAFLUSH : :: c_int = 0x2 ;
@@ -473,6 +470,38 @@ pub const F_GETLK: ::c_int = 5;
473
470
pub const F_GETOWN : :: c_int = 9 ;
474
471
pub const F_SETOWN : :: c_int = 8 ;
475
472
473
+ pub const TCGETS : :: c_int = 0x5401 ;
474
+ pub const TCSETS : :: c_int = 0x5402 ;
475
+ pub const TCSETSW : :: c_int = 0x5403 ;
476
+ pub const TCSETSF : :: c_int = 0x5404 ;
477
+ pub const TCGETA : :: c_int = 0x5405 ;
478
+ pub const TCSETA : :: c_int = 0x5406 ;
479
+ pub const TCSETAW : :: c_int = 0x5407 ;
480
+ pub const TCSETAF : :: c_int = 0x5408 ;
481
+ pub const TCSBRK : :: c_int = 0x5409 ;
482
+ pub const TCXONC : :: c_int = 0x540A ;
483
+ pub const TCFLSH : :: c_int = 0x540B ;
484
+ pub const TIOCGSOFTCAR : :: c_int = 0x5419 ;
485
+ pub const TIOCSSOFTCAR : :: c_int = 0x541A ;
486
+ pub const TIOCINQ : :: c_int = 0x541B ;
487
+ pub const TIOCLINUX : :: c_int = 0x541C ;
488
+ pub const TIOCGSERIAL : :: c_int = 0x541E ;
489
+ pub const TIOCEXCL : :: c_int = 0x540C ;
490
+ pub const TIOCNXCL : :: c_int = 0x540D ;
491
+ pub const TIOCSCTTY : :: c_int = 0x540E ;
492
+ pub const TIOCGPGRP : :: c_int = 0x540F ;
493
+ pub const TIOCSPGRP : :: c_int = 0x5410 ;
494
+ pub const TIOCOUTQ : :: c_int = 0x5411 ;
495
+ pub const TIOCSTI : :: c_int = 0x5412 ;
496
+ pub const TIOCGWINSZ : :: c_int = 0x5413 ;
497
+ pub const TIOCSWINSZ : :: c_int = 0x5414 ;
498
+ pub const TIOCMGET : :: c_int = 0x5415 ;
499
+ pub const TIOCMBIS : :: c_int = 0x5416 ;
500
+ pub const TIOCMBIC : :: c_int = 0x5417 ;
501
+ pub const TIOCMSET : :: c_int = 0x5418 ;
502
+ pub const FIONREAD : :: c_int = 0x541B ;
503
+ pub const TIOCCONS : :: c_int = 0x541D ;
504
+
476
505
f ! {
477
506
pub fn sigemptyset( set: * mut sigset_t) -> :: c_int {
478
507
* set = 0 ;
@@ -508,18 +537,18 @@ f! {
508
537
return 0
509
538
}
510
539
pub fn tcgetattr( fd: :: c_int, termios: * mut :: termios) -> :: c_int {
511
- ioctl( fd, TCGETS , termios)
540
+ ioctl( fd, :: TCGETS , termios)
512
541
}
513
542
pub fn tcsetattr( fd: :: c_int,
514
543
optional_actions: :: c_int,
515
544
termios: * const :: termios) -> :: c_int {
516
545
ioctl( fd, optional_actions, termios)
517
546
}
518
547
pub fn tcflow( fd: :: c_int, action: :: c_int) -> :: c_int {
519
- ioctl( fd, TCXONC , action as * mut :: c_void)
548
+ ioctl( fd, :: TCXONC , action as * mut :: c_void)
520
549
}
521
550
pub fn tcflush( fd: :: c_int, action: :: c_int) -> :: c_int {
522
- ioctl( fd, TCFLSH , action as * mut :: c_void)
551
+ ioctl( fd, :: TCFLSH , action as * mut :: c_void)
523
552
}
524
553
pub fn tcsendbreak( fd: :: c_int, duration: :: c_int) -> :: c_int {
525
554
ioctl( fd, TCSBRKP , duration as * mut :: c_void)
0 commit comments