Show More
@@ -415,12 +415,15 b' class revlog(object):' | |||
|
415 | 415 | raise error.RevlogError(_('revlog chunk cache size %r is not a ' |
|
416 | 416 | 'power of 2') % self._chunkcachesize) |
|
417 | 417 | |
|
418 | self._loadindex(v, mmapindexthreshold) | |
|
419 | ||
|
420 | def _loadindex(self, v, mmapindexthreshold): | |
|
418 | 421 | indexdata = '' |
|
419 | 422 | self._initempty = True |
|
420 | 423 | try: |
|
421 | 424 | with self._indexfp() as f: |
|
422 | 425 | if (mmapindexthreshold is not None and |
|
423 |
|
|
|
426 | self.opener.fstat(f).st_size >= mmapindexthreshold): | |
|
424 | 427 | indexdata = util.buffer(util.mmapread(f)) |
|
425 | 428 | else: |
|
426 | 429 | indexdata = f.read() |
General Comments 0
You need to be logged in to leave comments.
Login now