# HG changeset patch # User Benoit Boissinot # Date 1161156383 -7200 # Node ID 27ebe4efe98ea1d6da1d6714ca55cfeae4f3bc4e # Parent c8686e3f0291fb77553b053a422c0d84337aef57 invalidate the branch cache when sanity check fails diff -r c8686e3f0291 -r 27ebe4efe98e mercurial/localrepo.py --- a/mercurial/localrepo.py Wed Oct 18 02:14:26 2006 -0500 +++ b/mercurial/localrepo.py Wed Oct 18 09:26:23 2006 +0200 @@ -304,10 +304,11 @@ for l in f: node, label = l.rstrip().split(" ", 1) self.branchcache[label] = bin(node) + else: # invalidate the cache + last, lrev = nullid, -1 f.close() except IOError: last, lrev = nullid, -1 - lrev = self.changelog.rev(last) tip = self.changelog.count() - 1 if lrev != tip: