Use syscall.TIOCGPTN and syscall.TIOCSPTLCK for ioctl

Signed-off-by: Yohei Ueda <yohei@jp.ibm.com>
This commit is contained in:
Yohei Ueda
2014-11-25 10:32:31 +00:00
parent 67e2db24c8
commit b1c5cc8377

View File

@@ -8,8 +8,8 @@ import (
)
var (
ioctl_TIOCGPTN = _IOR('T', 0x30, unsafe.Sizeof(_C_uint(0))) /* Get Pty Number (of pty-mux device) */
ioctl_TIOCSPTLCK = _IOW('T', 0x31, unsafe.Sizeof(_C_int(0))) /* Lock/unlock Pty */
ioctl_TIOCGPTN = uintptr(syscall.TIOCGPTN) /* Get Pty Number (of pty-mux device) */
ioctl_TIOCSPTLCK = uintptr(syscall.TIOCSPTLCK) /* Lock/unlock Pty */
)
func open() (pty, tty *os.File, err error) {