summaryrefslogtreecommitdiffstats
path: root/lirc_mp.c
diff options
context:
space:
mode:
authorarpi <arpi@b3059339-0415-0410-9bf9-f77b7e298cf2>2001-10-07 17:19:22 +0000
committerarpi <arpi@b3059339-0415-0410-9bf9-f77b7e298cf2>2001-10-07 17:19:22 +0000
commitd195cabadeb20ccfdad71960b9f06354d8af1730 (patch)
treeb45c7b3b78a346d796c6d3b50cf1d84f9f53a91e /lirc_mp.c
parentf2facc7e714e641f75de0ab0a904fc9ade4cb630 (diff)
downloadmpv-d195cabadeb20ccfdad71960b9f06354d8af1730.tar.bz2
mpv-d195cabadeb20ccfdad71960b9f06354d8af1730.tar.xz
keypress fix by M.Hunold@t-online.de (Michael Hunold)
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@2123 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'lirc_mp.c')
-rw-r--r--lirc_mp.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/lirc_mp.c b/lirc_mp.c
index bd1642222e..2ef3046ade 100644
--- a/lirc_mp.c
+++ b/lirc_mp.c
@@ -135,6 +135,16 @@ int lirc_mp_getinput(){
}
}
+ // the lirc support is "broken by design": (see mailing list discussion)
+ // we only accept one command at each call of this subroutine, but the
+ // "lirc_code2char()" function should be called in a loop
+ // until it reports "empty"... (see lirc documentation)
+ // so we need to flush the lirc command queue after we processed one
+ // command. of course we report if we really lose a message.
+ while((ret=lirc_code2char(lirc_config,code,&c))==0 && c!=NULL){
+ fprintf(stderr, "LIRC: lost command \"%s\"",c);
+ }
+
free(code);
if(ret==-1){
mp_msg(MSGT_LIRC,MSGL_V,"LIRC: lirc_code2char() returned an error!\n");