Andrew Wilkins | 4ffbbd7 | 2015-05-23 15:16:09 +0000 | [diff] [blame] | 1 | // +build darwin |
2 | |||||
3 | package liner | ||||
4 | |||||
5 | import "syscall" | ||||
6 | |||||
7 | const ( | ||||
8 | getTermios = syscall.TIOCGETA | ||||
9 | setTermios = syscall.TIOCSETA | ||||
10 | ) | ||||
11 | |||||
12 | const ( | ||||
13 | // Input flags | ||||
14 | inpck = 0x010 | ||||
15 | istrip = 0x020 | ||||
16 | icrnl = 0x100 | ||||
17 | ixon = 0x200 | ||||
18 | |||||
19 | // Output flags | ||||
20 | opost = 0x1 | ||||
21 | |||||
22 | // Control flags | ||||
23 | cs8 = 0x300 | ||||
24 | |||||
25 | // Local flags | ||||
26 | isig = 0x080 | ||||
27 | icanon = 0x100 | ||||
28 | iexten = 0x400 | ||||
29 | ) | ||||
30 | |||||
31 | type termios struct { | ||||
32 | Iflag uintptr | ||||
33 | Oflag uintptr | ||||
34 | Cflag uintptr | ||||
35 | Lflag uintptr | ||||
36 | Cc [20]byte | ||||
37 | Ispeed uintptr | ||||
38 | Ospeed uintptr | ||||
39 | } |