Minor caching improvement for manifest
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Minor caching improvement for manifest
manifest hash:
91d827f4041f1151875a52199618cdd1a219ac79
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)
iD8DBQFCrGGBywK+sNU5EO8RAotVAJ93JTk6XoHnZrbGzcZQ1N+P7kNKiACfYj+F
RlcmcLHc3rEMkcM127BszDg=
=5zAN
-----END PGP SIGNATURE-----
--- a/mercurial/hg.py Sun Jun 12 08:11:43 2005 -0800
+++ b/mercurial/hg.py Sun Jun 12 08:23:29 2005 -0800
@@ -97,6 +97,7 @@
revlog.__init__(self, opener, "00manifest.i", "00manifest.d")
def read(self, node):
+ if node == nullid: return {} # don't upset local cache
if self.mapcache and self.mapcache[0] == node:
return self.mapcache[1].copy()
text = self.revision(node)
@@ -111,6 +112,7 @@
return map
def readflags(self, node):
+ if node == nullid: return {} # don't upset local cache
if self.mapcache or self.mapcache[0] != node:
self.read(node)
return self.mapcache[2]