mirror of
https://github.com/SantaSpeen/BeamMP-Server.git
synced 2026-06-17 21:20:52 +00:00
use read(..., ..., 1) instead of getchar
This commit is contained in:
+1
-1
@@ -87,7 +87,7 @@ void resetTermios(void) {
|
|||||||
char getch_(int echo) {
|
char getch_(int echo) {
|
||||||
char ch;
|
char ch;
|
||||||
initTermios(echo);
|
initTermios(echo);
|
||||||
ch = getchar();
|
read(STDIN_FILENO, &ch, 1);
|
||||||
resetTermios();
|
resetTermios();
|
||||||
return ch;
|
return ch;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user