mirror of
https://github.com/moby/moby.git
synced 2022-11-09 12:21:53 -05:00
[pkg/term] switch more syscalls to /x/sys/
Switches the remaining syscalls except Errno to /x/sys/. This was supposed to be part of 33180 Signed-off-by: Christopher Jones <tophj@linux.vnet.ibm.com>
This commit is contained in:
parent
23e857cd3d
commit
df6dfcf198
1 changed files with 6 additions and 6 deletions
|
@ -13,7 +13,7 @@ import (
|
||||||
import "C"
|
import "C"
|
||||||
|
|
||||||
// Termios is the Unix API for terminal I/O.
|
// Termios is the Unix API for terminal I/O.
|
||||||
// It is passthrough for syscall.Termios in order to make it portable with
|
// It is passthrough for unix.Termios in order to make it portable with
|
||||||
// other platforms where it is not available or handled differently.
|
// other platforms where it is not available or handled differently.
|
||||||
type Termios unix.Termios
|
type Termios unix.Termios
|
||||||
|
|
||||||
|
@ -28,11 +28,11 @@ func MakeRaw(fd uintptr) (*State, error) {
|
||||||
|
|
||||||
newState := oldState.termios
|
newState := oldState.termios
|
||||||
|
|
||||||
newState.Iflag &^= (syscall.IGNBRK | syscall.BRKINT | syscall.PARMRK | syscall.ISTRIP | syscall.INLCR | syscall.IGNCR | syscall.ICRNL | syscall.IXON | syscall.IXANY)
|
newState.Iflag &^= (unix.IGNBRK | unix.BRKINT | unix.PARMRK | unix.ISTRIP | unix.INLCR | unix.IGNCR | unix.ICRNL | unix.IXON | unix.IXANY)
|
||||||
newState.Oflag &^= syscall.OPOST
|
newState.Oflag &^= unix.OPOST
|
||||||
newState.Lflag &^= (syscall.ECHO | syscall.ECHONL | syscall.ICANON | syscall.ISIG | syscall.IEXTEN)
|
newState.Lflag &^= (unix.ECHO | unix.ECHONL | unix.ICANON | unix.ISIG | unix.IEXTEN)
|
||||||
newState.Cflag &^= (syscall.CSIZE | syscall.PARENB)
|
newState.Cflag &^= (unix.CSIZE | unix.PARENB)
|
||||||
newState.Cflag |= syscall.CS8
|
newState.Cflag |= unix.CS8
|
||||||
|
|
||||||
/*
|
/*
|
||||||
VMIN is the minimum number of characters that needs to be read in non-canonical mode for it to be returned
|
VMIN is the minimum number of characters that needs to be read in non-canonical mode for it to be returned
|
||||||
|
|
Loading…
Add table
Reference in a new issue