problem with VDR 1.3.39

Message ID 43CBD2D8.2040003@cadsoft.de
State New
Headers

Commit Message

Klaus Schmidinger Jan. 16, 2006, 5:07 p.m. UTC
  Peter Juszack wrote:
> Hi list,
> 
>    after updating to 1.3.39 vdr did react on keys any more. With 1.3.38 
> everything worked fine.
> 
> in syslog I discovered the following
> 
> Jan 16 13:47:32 fontina vdr[4440]: ERROR: unknown plugin 'snapshot'
> Jan 16 13:48:03 fontina last message repeated 341237 times
> Jan 16 13:48:05 fontina last message repeated 33642 times
> 
> after some searching I discovered that the snapshot plugin remained in 
> the keymacros.conf allthough I
> have uninstalled it.
> After I tidied up the keymacros.conf everything is fine.

Here's a fix:



Actually either one of these changes will do, but it's certainly not
a bad idea to make cKeyMacros::Get() "kNone-safe" as well.

Klaus
  

Comments

Markus Hahn Jan. 17, 2006, 2:13 p.m. UTC | #1
Am Montag, 16. Januar 2006 18:07 schrieb Klaus Schmidinger:
> Peter Juszack wrote:
> > Hi list,
> >
> > in syslog I discovered the following

> > Jan 16 13:48:05 fontina last message repeated 33642 times
> >
> > After I tidied up the keymacros.conf everything is fine.
>
> Here's a fix:
>
> --- keys.c      2006/01/05 15:39:26     1.10
> +++ keys.c      2006/01/16 17:01:25

thank you for  the fix klaus. I had  the same Probleme today with some nice 
side effect: OSD was after the first channelInfo disabled!! 

regards Markus
  

Patch

--- keys.c      2006/01/05 15:39:26     1.10
+++ keys.c      2006/01/16 17:01:25
@@ -250,9 +250,11 @@ 

  const cKeyMacro *cKeyMacros::Get(eKeys Key)
  {
-  for (cKeyMacro *k = First(); k; k = Next(k)) {
-      if (*k->Macro() == Key)
-         return k;
-      }
+  if (Key != kNone) {
+     for (cKeyMacro *k = First(); k; k = Next(k)) {
+         if (*k->Macro() == Key)
+            return k;
+         }
+     }
    return NULL;
  }
--- vdr.c       2006/01/15 16:23:21     1.240
+++ vdr.c       2006/01/16 17:05:49
@@ -985,7 +985,7 @@ 
             }
          else {
             // Key functions in "normal" viewing mode:
-           if (KeyMacros.Get(key)) {
+           if (key != kNone && KeyMacros.Get(key)) {
                cRemote::PutMacro(key);
                key = kNone;
                }