mq: qsave creates entries with the left part empty (':patchname')
authorBenoit Boissinot <benoit.boissinot@ens-lyon.org>
Sun, 14 Mar 2010 11:12:07 +0100
changeset 10683 cfbf064f0069
parent 10682 8ed350051896
child 10684 485c1d7f8a77
mq: qsave creates entries with the left part empty (':patchname')
hgext/mq.py
--- a/hgext/mq.py	Sun Mar 14 01:35:54 2010 +0100
+++ b/hgext/mq.py	Sun Mar 14 11:12:07 2010 +0100
@@ -1488,12 +1488,11 @@
                 qpp = [bin(x) for x in l]
             elif datastart != None:
                 l = line.rstrip()
-                try:
-                    n, name = l.split(':', 1)
-                except ValueError:
+                n, name = l.split(':', 1)
+                if n:
+                    applied.append(statusentry(bin(n), name))
+                else:
                     series.append(l)
-                else:
-                    applied.append(statusentry(bin(n), name))
         if datastart is None:
             self.ui.warn(_("No saved patch data found\n"))
             return 1