Show More
@@ -2592,7 +2592,7 b' def perfrevlogindex(ui, repo, file_=None' | |||||
2592 | index[rev] |
|
2592 | index[rev] | |
2593 |
|
2593 | |||
2594 | def resolvenode(node): |
|
2594 | def resolvenode(node): | |
2595 |
nodemap = revlogio.parseindex(data, inline)[ |
|
2595 | nodemap = getattr(revlogio.parseindex(data, inline)[0], 'nodemap', None) | |
2596 | # This only works for the C code. |
|
2596 | # This only works for the C code. | |
2597 | if nodemap is None: |
|
2597 | if nodemap is None: | |
2598 | return |
|
2598 | return | |
@@ -2603,7 +2603,7 b' def perfrevlogindex(ui, repo, file_=None' | |||||
2603 | pass |
|
2603 | pass | |
2604 |
|
2604 | |||
2605 | def resolvenodes(nodes, count=1): |
|
2605 | def resolvenodes(nodes, count=1): | |
2606 |
nodemap = revlogio.parseindex(data, inline)[ |
|
2606 | nodemap = getattr(revlogio.parseindex(data, inline)[0], 'nodemap', None) | |
2607 | if nodemap is None: |
|
2607 | if nodemap is None: | |
2608 | return |
|
2608 | return | |
2609 |
|
2609 |
@@ -252,7 +252,7 b' class revlogoldio(object):' | |||||
252 | n += 1 |
|
252 | n += 1 | |
253 |
|
253 | |||
254 | index = revlogoldindex(index) |
|
254 | index = revlogoldindex(index) | |
255 |
return index, |
|
255 | return index, None | |
256 |
|
256 | |||
257 | def packentry(self, entry, node, version, rev): |
|
257 | def packentry(self, entry, node, version, rev): | |
258 | if gettype(entry[0]): |
|
258 | if gettype(entry[0]): | |
@@ -299,7 +299,7 b' class revlogio(object):' | |||||
299 | def parseindex(self, data, inline): |
|
299 | def parseindex(self, data, inline): | |
300 | # call the C implementation to parse the index data |
|
300 | # call the C implementation to parse the index data | |
301 | index, cache = parsers.parse_index2(data, inline) |
|
301 | index, cache = parsers.parse_index2(data, inline) | |
302 |
return index, |
|
302 | return index, cache | |
303 |
|
303 | |||
304 | def packentry(self, entry, node, version, rev): |
|
304 | def packentry(self, entry, node, version, rev): | |
305 | p = indexformatng_pack(*entry) |
|
305 | p = indexformatng_pack(*entry) | |
@@ -552,8 +552,8 b' class revlog(object):' | |||||
552 | raise error.RevlogError( |
|
552 | raise error.RevlogError( | |
553 | _(b"index %s is corrupted") % self.indexfile |
|
553 | _(b"index %s is corrupted") % self.indexfile | |
554 | ) |
|
554 | ) | |
555 |
self.index |
|
555 | self.index, self._chunkcache = d | |
556 | self.nodemap = self._nodecache = nodemap |
|
556 | self.nodemap = self._nodecache = self.index.nodemap | |
557 | if not self._chunkcache: |
|
557 | if not self._chunkcache: | |
558 | self._chunkclear() |
|
558 | self._chunkclear() | |
559 | # revnum -> (chain-length, sum-delta-length) |
|
559 | # revnum -> (chain-length, sum-delta-length) |
General Comments 0
You need to be logged in to leave comments.
Login now