Mailing List archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[vdr] Re: Bugfix-patch for the show replay mode -crash



Kimmo Tykkala wrote:
> 
> Hi,
> 
> On Wed, 28 Jul 2004, Achim Tuffentsammer wrote:
> > Kimmo Tykkala wrote:
> >
> > >Press fast-forward/rewind/pause button while the menu is on.
> > >VDR crashes immediately and writes the following line to the
> > >/var/log/messages -file:
> > >Jul 27 21:16:42 tiivitaavi vdr[2684]: ERROR: attempt to open OSD
> while
> > >it is already open!
> > >
> > >If the "show replay mode" is turned off, the crash won't happen.
> > >
> > >
> > I can confirm this crash. When this error occurs cOsdProvider::NewOsd
> > returns NULL. There are several places in the source code where this
> is
> > not checked for NULL.
> >
> 
> attached is a small fix for the bug described above.
> 
> The fix is a couple of NULL-checkings before the skins try
> to show the replay mode -indicator on screen. With the fix the
> replay mode will change, but VDR does not try to show the changed
> replay mode if the screen is already occupied by the menu.
> 
> The patch is written for 1.3.12 and it fixes both the classic and new
> VDR-skin.

Sorry about the empty reply I just sent - I've hit the wrong button...

I believe there shouldn't be any attempt to create a replay display
in the first place if the OSD is in use, so I would suggest this:


--- menu.c      2004/08/08 14:29:14     1.311
+++ menu.c      2004/08/08 15:13:40
@@ -3081,7 +3081,7 @@
 
 void cReplayControl::ShowMode(void)
 {
-  if (visible || Setup.ShowReplayMode) {
+  if (visible || Setup.ShowReplayMode && !cOsd::IsOpen()) {
      bool Play, Forward;
      int Speed;
      if (GetReplayMode(Play, Forward, Speed) && (!visible || Play != lastPlay || Forward != lastForward || Speed != lastSpeed)) {



Klaus




Home | Main Index | Thread Index