Mailing List archive

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

[vdr] Re: emergency exit but no restart



Klaus Schmidinger wrote:
> Uwe Weissbach wrote:
> > 10 min for the answer! It seems you're always active...
> > by the way thanks for thousands of hours of your work.....
> >
> > > The runvdr script looks ok. Are you adding any further command
> > > line options when
> > > calling it (especially '-d')?
> > >
> > > Please make sure none of your patches messes up with the return
> > > level of the main program (in vdr.c). In case of an emergency
> > > exit it has to return 1.
> > > Here's how the end of vdr.c should look:
> > >
> > >   if (cThread::EmergencyExit()) {
> > >      esyslog("emergency exit!");
> > >      return 1;
> > >      }
> > >   return 0;
> >
> > runvdr is called from /etc/initab with
> > vdr:235:once:/usr/local/bin/runvdr
> > --shutdown=/usr/local/bin/vdrshutdown --terminal=/dev/tty8
> > --config=/etc/vdr --epgfile=/var/vdr/epg.data seems o.k. for me
> > in case of the patches, I don't know wich patch messes with return
> > levels I have:
> > REMOTE=LIRC DVD=1 MPLAYER=1 MP3=1 VFAT=1 CB=1 COLOR=1 FONT=SMALL
> > TECH=1 but the end of the patched vdr.c looks like as you say with
> > the only change of this LOG_ERR. As far as I can see this does'nt
> > affects the return level...
>
> Sorry, I posted the version from the 1.1.x branch. But that should
> make no difference.
>
> >   if (cThread::EmergencyExit()) {
> >      esyslog(LOG_ERR, "emergency exit!");
> >      return 1;
> >      }
> >   return 0;
> >
> > Anything I can do to check this furthermore...?
>
> Well, nothing I could think of. Apparently from the log entries you
> posted VDR does go through the "return 1;" statement, but in the
> runvdr script it believes the return value is 0.
>
> You could remove the line
>
>   if test $? -eq 0; then exit; fi
>
> from the runvdr script. Then it shouldn't exit from the script at
> all.

I just noticed that 'su' returns zero if vdr exits due to a runtime 
error. Try the following:
- ./runvdr (vanilla runvdr, vdr 1.1.11)
- press 'menu'
- press 'blue'
vdr crashes and runvdr terminates.

If you remove 'su' you get the diagnostic message
'./runvdr: line 51:  1291 Speicherzugriffsfehler  $VDRCMD'
and return code 139. Strange...

Oliver

P.S.:
I tracked this crash down to recording.c(998), cFileName constructor:
fileName = new char[strlen(FileName) + RECORDFILESUFFIXLEN]
is called with FileName==NULL. The call originates from vdr.c (500):  
cControl::Launch(new cReplayControl).



-- 
Info:
To unsubscribe send a mail to listar@linuxtv.org with "unsubscribe vdr" as subject.



Home | Main Index | Thread Index