|
|
@ -397,7 +397,7 @@ namespace DFHack
|
|
|
|
// We want read to return every single byte, without timeout.
|
|
|
|
// We want read to return every single byte, without timeout.
|
|
|
|
raw.c_cc[VMIN] = 1; raw.c_cc[VTIME] = 0;// 1 byte, no timer
|
|
|
|
raw.c_cc[VMIN] = 1; raw.c_cc[VTIME] = 0;// 1 byte, no timer
|
|
|
|
// put terminal in raw mode after flushing
|
|
|
|
// put terminal in raw mode after flushing
|
|
|
|
if (tcsetattr(STDIN_FILENO,TCSAFLUSH,&raw) < 0)
|
|
|
|
if (tcsetattr(STDIN_FILENO,TCSADRAIN,&raw) < 0)
|
|
|
|
return -1;
|
|
|
|
return -1;
|
|
|
|
rawmode = 1;
|
|
|
|
rawmode = 1;
|
|
|
|
return 0;
|
|
|
|
return 0;
|
|
|
|