xineliboutput: keyboard read fix

Message ID E1GWXpn-0003Cc-00@bigred.inka.de
State New
Headers

Commit Message

Olaf Titz Oct. 8, 2006, 12:32 p.m. UTC
  This trivial patch (for xineliboutput-1.0.0p5) fixes the situation
with a remote frontend where stdin is not connected to a keyboard. The
keyboard thread would not recognize an EOF condition (e.g. /dev/null)
and spin at 100% CPU. (Same with pressing Ctrl-D I guess.)
Perhaps the whole thing should just use -1 for EOF but that would need
a fix in several places.

Olaf



=== end of patch ===
  

Patch

--- xine_frontend_main.c~	2006-10-08 13:02:46.000000000 +0200
+++ xine_frontend_main.c	2006-10-08 13:02:46.000000000 +0200
@@ -57,7 +57,7 @@ 
       return -2;
     }
   }
-  return -1;
+  return 0xffff;
 }

 static uint64_t read_key_seq(void)