diff mercurial/hg.py @ 311:3b17056b72dc

fix KeyErrors from reading empty dirstate -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 fix KeyErrors from reading empty dirstate manifest hash: 04a797f1b53e34153c8ea18950a5dd0eefb4694d -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.0 (GNU/Linux) iD4DBQFCqyj+ywK+sNU5EO8RAoepAJYp2TjjaMq3l+ZrRfogyvUGCebgAJ9nKPdr nP/Y3F1GvOle58NTIQ6UBA== =0k3O -----END PGP SIGNATURE-----
author mpm@selenic.com
date Sat, 11 Jun 2005 10:10:06 -0800
parents 075619d00dd7
children 09375250eb31
line wrap: on
line diff
--- a/mercurial/hg.py	Fri Jun 10 14:10:07 2005 -0800
+++ b/mercurial/hg.py	Sat Jun 11 10:10:06 2005 -0800
@@ -219,6 +219,7 @@
         self.pl = [nullid, nullid]
         try:
             st = self.opener("dirstate").read()
+            if not st: return
         except: return
 
         self.pl = [st[:20], st[20: 40]]