Show More
@@ -360,19 +360,26 b' class revlogio(object):' | |||
|
360 | 360 | n = off = 0 |
|
361 | 361 | # if we're not using lazymap, always read the whole index |
|
362 | 362 | data = fp.read() |
|
363 | l = len(data) | |
|
363 | l = len(data) - s | |
|
364 | unpack = struct.unpack | |
|
365 | append = index.append | |
|
364 | 366 | if inline: |
|
365 | 367 | cache = (0, data) |
|
366 |
while off |
|
|
367 |
e = |
|
|
368 | index.append(e) | |
|
368 | while off <= l: | |
|
369 | e = unpack(indexformatng, data[off:off + s]) | |
|
369 | 370 | nodemap[e[7]] = n |
|
371 | append(e) | |
|
372 | n += 1 | |
|
373 | if e[1] < 0: | |
|
374 | break | |
|
375 | off += e[1] + s | |
|
376 | else: | |
|
377 | while off <= l: | |
|
378 | e = unpack(indexformatng, data[off:off + s]) | |
|
379 | nodemap[e[7]] = n | |
|
380 | append(e) | |
|
370 | 381 | n += 1 |
|
371 | 382 | off += s |
|
372 | if inline: | |
|
373 | if e[1] < 0: | |
|
374 | break | |
|
375 | off += e[1] | |
|
376 | 383 | |
|
377 | 384 | e = list(index[0]) |
|
378 | 385 | type = gettype(e[0]) |
General Comments 0
You need to be logged in to leave comments.
Login now