Show More
@@ -324,16 +324,18 b' class localrepository(repo.repository):' | |||||
324 | partial = {} |
|
324 | partial = {} | |
325 | try: |
|
325 | try: | |
326 | f = self.opener("branches.cache") |
|
326 | f = self.opener("branches.cache") | |
327 |
l |
|
327 | lines = f.read().split('\n') | |
|
328 | f.close() | |||
|
329 | last, lrev = lines.pop(0).rstrip().split(" ", 1) | |||
328 | last, lrev = bin(last), int(lrev) |
|
330 | last, lrev = bin(last), int(lrev) | |
329 | if (lrev < self.changelog.count() and |
|
331 | if (lrev < self.changelog.count() and | |
330 | self.changelog.node(lrev) == last): # sanity check |
|
332 | self.changelog.node(lrev) == last): # sanity check | |
331 |
for l in |
|
333 | for l in lines: | |
|
334 | if not l: continue | |||
332 | node, label = l.rstrip().split(" ", 1) |
|
335 | node, label = l.rstrip().split(" ", 1) | |
333 | partial[label] = bin(node) |
|
336 | partial[label] = bin(node) | |
334 | else: # invalidate the cache |
|
337 | else: # invalidate the cache | |
335 | last, lrev = nullid, nullrev |
|
338 | last, lrev = nullid, nullrev | |
336 | f.close() |
|
|||
337 | except IOError: |
|
339 | except IOError: | |
338 | last, lrev = nullid, nullrev |
|
340 | last, lrev = nullid, nullrev | |
339 | return partial, last, lrev |
|
341 | return partial, last, lrev |
General Comments 0
You need to be logged in to leave comments.
Login now