зеркало из https://github.com/microsoft/docker.git
Add the ISIG syscall back to not kill the client withing a shell with ctrl+c.
This commit is contained in:
Родитель
f18889bf67
Коммит
b54ba5095b
|
@ -44,7 +44,7 @@ func MakeRaw(fd uintptr) (*State, error) {
|
|||
newState.Iflag &^= (ISTRIP | INLCR | IGNCR | IXON | IXOFF)
|
||||
newState.Iflag |= ICRNL
|
||||
newState.Oflag |= ONLCR
|
||||
newState.Lflag &^= (ECHO | ICANON)
|
||||
newState.Lflag &^= (ECHO | ICANON | ISIG)
|
||||
|
||||
if _, _, err := syscall.Syscall(syscall.SYS_IOCTL, fd, uintptr(setTermios), uintptr(unsafe.Pointer(&newState))); err != 0 {
|
||||
return nil, err
|
||||
|
|
|
@ -33,7 +33,7 @@ func MakeRaw(fd uintptr) (*State, error) {
|
|||
|
||||
newState.Iflag &^= (syscall.IGNBRK | syscall.BRKINT | syscall.PARMRK | syscall.ISTRIP | syscall.INLCR | syscall.IGNCR | syscall.ICRNL | syscall.IXON)
|
||||
newState.Oflag &^= syscall.OPOST
|
||||
newState.Lflag &^= (syscall.ECHO | syscall.ECHONL | syscall.ICANON | syscall.IEXTEN)
|
||||
newState.Lflag &^= (syscall.ECHO | syscall.ECHONL | syscall.ICANON | syscall.ISIG | syscall.EXTEN)
|
||||
newState.Cflag &^= (syscall.CSIZE | syscall.PARENB)
|
||||
newState.Cflag |= syscall.CS8
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче