mirror of
https://github.com/BeamMP/BeamMP-Server.git
synced 2025-07-04 00:36:14 +00:00
fix ignored return value in getch_
This commit is contained in:
parent
3c4737a145
commit
dbb01998ea
@ -50,7 +50,9 @@ TEST_CASE("init and reset termios") {
|
|||||||
static char getch_(int echo) {
|
static char getch_(int echo) {
|
||||||
char ch;
|
char ch;
|
||||||
initTermios(echo);
|
initTermios(echo);
|
||||||
(void)read(STDIN_FILENO, &ch, 1);
|
if (read(STDIN_FILENO, &ch, 1) < 0) {
|
||||||
|
// ignore, not much we can do
|
||||||
|
}
|
||||||
resetTermios();
|
resetTermios();
|
||||||
return ch;
|
return ch;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user