##// END OF EJS Templates
If we can't write the branch cache, fail quietly.
Matt Mackall -
r3452:fcf14d87 default
parent child Browse files
Show More
@@ -322,11 +322,14 b' class localrepository(repo.repository):'
322 return self.branchcache
322 return self.branchcache
323
323
324 def _writebranchcache(self):
324 def _writebranchcache(self):
325 try:
325 f = self.opener("branches.cache", "w")
326 f = self.opener("branches.cache", "w")
326 t = self.changelog.tip()
327 t = self.changelog.tip()
327 f.write("%s %s\n" % (hex(t), self.changelog.count() - 1))
328 f.write("%s %s\n" % (hex(t), self.changelog.count() - 1))
328 for label, node in self.branchcache.iteritems():
329 for label, node in self.branchcache.iteritems():
329 f.write("%s %s\n" % (hex(node), label))
330 f.write("%s %s\n" % (hex(node), label))
331 except IOError:
332 pass
330
333
331 def lookup(self, key):
334 def lookup(self, key):
332 if key == '.':
335 if key == '.':
General Comments 0
You need to be logged in to leave comments. Login now