Update of /cvsroot/freevo/freevo/src/helpers
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv10350/src/helpers
Modified Files:
recordserver.py
Log Message:
Add warnings in case the recording plugin isn't there.
Index: recordserver.py
===================================================================
RCS file: /cvsroot/freevo/freevo/src/helpers/recordserver.py,v
retrieving revision 1.53
retrieving revision 1.54
diff -C2 -d -r1.53 -r1.54
*** recordserver.py 9 Jul 2004 16:20:54 -0000 1.53
--- recordserver.py 9 Jul 2004 21:05:46 -0000 1.54
***************
*** 7,10 ****
--- 7,13 ----
# -----------------------------------------------------------------------
# $Log$
+ # Revision 1.54 2004/07/09 21:05:46 rshortt
+ # Add warnings in case the recording plugin isn't there.
+ #
# Revision 1.53 2004/07/09 16:20:54 outlyer
# Remove the request logging for 0-level debug. Exceptions will still be
***************
*** 142,145 ****
--- 145,162 ----
+ def print_plugin_warning():
+ print '*************************************************'
+ print '** Warning: No recording plugin registered. **'
+ print '** Check your local_conf.py for a **'
+ print '** bad "plugin_record =" line or **'
+ print '** this log for a plugin failure. **'
+ print '** Recordings will fail! **'
+ print '*************************************************'
+
+
+ if not plugin.getbyname('RECORD'):
+ print_plugin_warning()
+
+
class RecordServer(xmlrpc.XMLRPC):
***************
*** 255,259 ****
if recording:
print 'stopping current recording'
! plugin.getbyname('RECORD').Stop()
return (TRUE, 'recording removed')
--- 272,278 ----
if recording:
print 'stopping current recording'
! rec_plugin = plugin.getbyname('RECORD')
! if rec_plugin:
! rec_plugin.Stop()
return (TRUE, 'recording removed')
***************
*** 445,448 ****
--- 464,474 ----
_debug_('start recording')
self.record_app = plugin.getbyname('RECORD')
+
+ if not self.record_app:
+ print_plugin_warning()
+ print 'ERROR: Recording %s failed.' % String(rec_prog.title)
+ self.removeScheduledRecording(rec_prog)
+ return
+
self.record_app.Record(rec_prog)
-------------------------------------------------------
This SF.Net email sponsored by Black Hat Briefings & Training.
Attend Black Hat Briefings & Training, Las Vegas July 24-29 -
digital self defense, top technical experts, no vendor pitches,
unmatched networking opportunities. Visit www.blackhat.com
_______________________________________________
Freevo-cvslog mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-cvslog