Author: duncan
Date: Wed Nov  7 13:53:47 2007
New Revision: 10088

Log:
[ 1827184 ] nasty recordserver bug
Patch from Andrea Mennucc applied


Modified:
   branches/rel-1-7/freevo/ChangeLog
   branches/rel-1-7/freevo/src/util/marmalade.py
   branches/rel-1/freevo/ChangeLog
   branches/rel-1/freevo/src/util/marmalade.py

Modified: branches/rel-1-7/freevo/ChangeLog
==============================================================================
--- branches/rel-1-7/freevo/ChangeLog   (original)
+++ branches/rel-1-7/freevo/ChangeLog   Wed Nov  7 13:53:47 2007
@@ -48,6 +48,7 @@
  * Fixed favourite crashing because of duplicate detection flag 
(B#1778494,B#1777726)
  * Fixed matching favourites, by initially restricting the search (B#1776072)
  * Fixed mixer plug-ins to allow a configurable volume step size (B#1813088)
+ * Fixed recordserver sometimes corrupting the record schedule (B#1827184)
  * Fixed screensaver crashing after a long run when an event is read 
(B#1778894)
  * Fixed tvmenu crashing because of the search plug-in (B#1774544)
 

Modified: branches/rel-1-7/freevo/src/util/marmalade.py
==============================================================================
--- branches/rel-1-7/freevo/src/util/marmalade.py       (original)
+++ branches/rel-1-7/freevo/src/util/marmalade.py       Wed Nov  7 13:53:47 2007
@@ -163,6 +163,12 @@
             retval = float(node.getAttribute("value"))
         elif node.tagName == "longint":
             retval = long(node.getAttribute("value"))
+        elif node.tagName == "bool":
+            retval = int(node.getAttribute("value"))
+            if retval:
+                retval = True
+            else:
+                retval = False
         elif node.tagName == "module":
             retval = namedModule(str(node.getAttribute("name")))
         elif node.tagName == "class":
@@ -318,6 +324,9 @@
             # so that the object will show up where it's referenced first NOT
             # by a method.
             node.appendChild(self.jellyToNode(obj.im_self))
+        elif hasattr(types, 'BooleanType') and objType is types.BooleanType:
+            node = self.document.createElement("bool")
+            node.setAttribute("value", str(int(obj)))
         elif objType is types.ModuleType:
             node = self.document.createElement("module")
             node.setAttribute("name", obj.__name__)
@@ -383,8 +392,10 @@
                 else:
                     if hasattr(obj, "__getstate__"):
                         state = obj.__getstate__()
-                    else:
+                    elif hasattr(obj, "__dict__"):
                         state = obj.__dict__
+                    else:
+                        raise "Unsupported type: %s %s" % 
(objType.__name__,repr(obj))
                     n = self.jellyToNode(state)
                     node.appendChild(n)
             else:

Modified: branches/rel-1/freevo/ChangeLog
==============================================================================
--- branches/rel-1/freevo/ChangeLog     (original)
+++ branches/rel-1/freevo/ChangeLog     Wed Nov  7 13:53:47 2007
@@ -53,6 +53,7 @@
  * Fixed favourite crashing because of duplicate detection flag 
(B#1778494,B#1777726)
  * Fixed matching favourites, by initially restricting the search (B#1776072)
  * Fixed mixer plug-ins to allow a configurable volume step size (B#1813088)
+ * Fixed recordserver sometimes corrupting the record schedule (B#1827184)
  * Fixed screensaver crashing after a long run when an event is read 
(B#1778894)
  * Fixed tvmenu crashing because of the search plug-in (B#1774544)
 

Modified: branches/rel-1/freevo/src/util/marmalade.py
==============================================================================
--- branches/rel-1/freevo/src/util/marmalade.py (original)
+++ branches/rel-1/freevo/src/util/marmalade.py Wed Nov  7 13:53:47 2007
@@ -163,6 +163,12 @@
             retval = float(node.getAttribute("value"))
         elif node.tagName == "longint":
             retval = long(node.getAttribute("value"))
+        elif node.tagName == "bool":
+            retval = int(node.getAttribute("value"))
+            if retval:
+                retval = True
+            else:
+                retval = False
         elif node.tagName == "module":
             retval = namedModule(str(node.getAttribute("name")))
         elif node.tagName == "class":
@@ -318,6 +324,9 @@
             # so that the object will show up where it's referenced first NOT
             # by a method.
             node.appendChild(self.jellyToNode(obj.im_self))
+        elif hasattr(types, 'BooleanType') and objType is types.BooleanType:
+            node = self.document.createElement("bool")
+            node.setAttribute("value", str(int(obj)))
         elif objType is types.ModuleType:
             node = self.document.createElement("module")
             node.setAttribute("name", obj.__name__)
@@ -383,8 +392,10 @@
                 else:
                     if hasattr(obj, "__getstate__"):
                         state = obj.__getstate__()
-                    else:
+                    elif hasattr(obj, "__dict__"):
                         state = obj.__dict__
+                    else:
+                        raise "Unsupported type: %s %s" % (objType.__name__, 
repr(obj))
                     n = self.jellyToNode(state)
                     node.appendChild(n)
             else:

-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
Freevo-cvslog mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/freevo-cvslog

Reply via email to