summaryrefslogtreecommitdiff
path: root/remote.c
diff options
context:
space:
mode:
authorKlaus Schmidinger <vdr@tvdr.de>2006-05-12 12:42:57 +0200
committerKlaus Schmidinger <vdr@tvdr.de>2006-05-12 12:42:57 +0200
commit81bd99a674117326a8b1a1eb7c7bb5b66f9739a6 (patch)
tree26d2a9dffc6d7dfb43b42dcffdd9f9aa9b4c6aae /remote.c
parentae7103e9843d5ea70048f1e96d672c3d194eee59 (diff)
downloadvdr-81bd99a674117326a8b1a1eb7c7bb5b66f9739a6.tar.gz
vdr-81bd99a674117326a8b1a1eb7c7bb5b66f9739a6.tar.bz2
Fixed handling unknown codes when learning LIRC remote control codes
Diffstat (limited to 'remote.c')
-rw-r--r--remote.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/remote.c b/remote.c
index c0b92867..a4277401 100644
--- a/remote.c
+++ b/remote.c
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: remote.c 1.50 2006/04/17 08:58:28 kls Exp $
+ * $Id: remote.c 1.51 2006/05/12 12:40:15 kls Exp $
*/
#include "remote.h"
@@ -182,11 +182,11 @@ eKeys cRemote::Get(int WaitMs, char **UnknownCode)
repeatTimeout.Set(REPEATTIMEOUT);
return k;
}
- else if (!WaitMs || !keyPressed.TimedWait(mutex, WaitMs) && repeatTimeout.TimedOut()) {
- if (learning && UnknownCode) {
- *UnknownCode = unknownCode;
- unknownCode = NULL;
- }
+ else if (!WaitMs || !keyPressed.TimedWait(mutex, WaitMs) && repeatTimeout.TimedOut())
+ return kNone;
+ else if (learning && UnknownCode && unknownCode) {
+ *UnknownCode = unknownCode;
+ unknownCode = NULL;
return kNone;
}
}