Skip to content
Snippets Groups Projects
Commit 0bbb5a7e authored by deuce's avatar deuce
Browse files

Set ansi_raw_inch to 0 if no bytes read.

parent ac8ce7ed
Branches
Tags
No related merge requests found
......@@ -385,8 +385,10 @@ static void ansi_keythread(void *params)
_beginthread(ansi_keyparse,1024,NULL);
for(;;) {
if(!ansi_raw_inch)
ansi_raw_inch=fgetc(stdin);
if(!ansi_raw_inch) {
if(read(fileno(stdin),&ansi_raw_inch,1)!=1)
ansi_raw_inch=0;
}
else
SLEEP(1);
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment