Mercurial > hg
changeset 3089:e7fc04dc6349
Avoid negative block sizes in lazyparser.
This fixes a bug introduced by changeset baa3873eb387 .
author | Alexis S. L. Carvalho <alexis@cecm.usp.br> |
---|---|
date | Wed, 13 Sep 2006 14:37:51 -0300 |
parents | dc784839516d |
children | eeaf9bcdfa25 |
files | mercurial/revlog.py |
diffstat | 1 files changed, 1 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/revlog.py Thu Sep 14 15:35:55 2006 +0200 +++ b/mercurial/revlog.py Wed Sep 13 14:37:51 2006 -0300 @@ -143,7 +143,7 @@ # the revlog may have grown since we've started running, # but we don't have space in self.index for more entries. # limit blocksize so that we don't get too much data. - blocksize = self.datasize - blockstart + blocksize = max(self.datasize - blockstart, 0) data = self.dataf.read(blocksize) lend = len(data) / self.s i = blockstart / self.s