]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
dunno
authorGuido van Rossum <guido@python.org>
Thu, 27 Apr 1995 18:05:36 +0000 (18:05 +0000)
committerGuido van Rossum <guido@python.org>
Thu, 27 Apr 1995 18:05:36 +0000 (18:05 +0000)
Demo/pdist/cvslib.py

index c98f0ba14a87205387e7e9d7926b8d2ee807d29c..61c74757ad00da6fb2518abce6e4750f9656beb5 100755 (executable)
@@ -14,10 +14,10 @@ class Entry:
                self.file = words[1]
                self.rev = words[2]
                dates = words[3] # ctime, mtime
-               if dates[:7] == 'Initial':
+               if len(dates) != 49 or dates[:7] == 'Initial':
                        self.ctime = None
                        self.mtime = None
-                       self.new = 1
+                       self.new = dates[:7] == 'Initial'
                else:
                        self.ctime = unctime(dates[:24])
                        self.mtime = unctime(dates[25:])
@@ -79,6 +79,8 @@ class CVS:
                        if not line: break
                        words = string.split(line)
                        [file, rev, hexsum] = words
+                       if not self.entries.has_key(file):
+                               continue
                        e = self.entries[file]
                        if e.rev == rev:
                                e.sethexsum(hexsum)