Show More
@@ -305,6 +305,7 b' class _deltacomputer(object):' | |||||
305 | grouped by level of easiness. |
|
305 | grouped by level of easiness. | |
306 | """ |
|
306 | """ | |
307 | revlog = self.revlog |
|
307 | revlog = self.revlog | |
|
308 | gdelta = revlog._generaldelta | |||
308 | curr = len(revlog) |
|
309 | curr = len(revlog) | |
309 | prev = curr - 1 |
|
310 | prev = curr - 1 | |
310 | p1r, p2r = revlog.rev(p1), revlog.rev(p2) |
|
311 | p1r, p2r = revlog.rev(p1), revlog.rev(p2) | |
@@ -316,13 +317,13 b' class _deltacomputer(object):' | |||||
316 | # changegroup data into a generaldelta repo. The only time it |
|
317 | # changegroup data into a generaldelta repo. The only time it | |
317 | # isn't true is if this is the first revision in a delta chain |
|
318 | # isn't true is if this is the first revision in a delta chain | |
318 | # or if ``format.generaldelta=true`` disabled ``lazydeltabase``. |
|
319 | # or if ``format.generaldelta=true`` disabled ``lazydeltabase``. | |
319 |
if cachedelta and |
|
320 | if cachedelta and gdelta and revlog._lazydeltabase: | |
320 | # Assume what we received from the server is a good choice |
|
321 | # Assume what we received from the server is a good choice | |
321 | # build delta will reuse the cache |
|
322 | # build delta will reuse the cache | |
322 | yield (cachedelta[0],) |
|
323 | yield (cachedelta[0],) | |
323 | tested.add(cachedelta[0]) |
|
324 | tested.add(cachedelta[0]) | |
324 |
|
325 | |||
325 |
if |
|
326 | if gdelta: | |
326 | # exclude already lazy tested base if any |
|
327 | # exclude already lazy tested base if any | |
327 | parents = [p for p in (p1r, p2r) |
|
328 | parents = [p for p in (p1r, p2r) | |
328 | if p != nullrev and p not in tested] |
|
329 | if p != nullrev and p not in tested] |
General Comments 0
You need to be logged in to leave comments.
Login now