On Wed, Aug 31, 2011 at 8:18 AM, justinpeel <nore...@buildbot.pypy.org> wrote: > Author: Justin Peel <notmuchtot...@gmail.com> > Branch: > Changeset: r46937:b4d8eb5fdf6c > Date: 2011-08-31 00:17 -0600 > http://bitbucket.org/pypy/pypy/changeset/b4d8eb5fdf6c/ > > Log: fix bz2. tests didn't find this. > > diff --git a/pypy/module/bz2/interp_bz2.py b/pypy/module/bz2/interp_bz2.py > --- a/pypy/module/bz2/interp_bz2.py > +++ b/pypy/module/bz2/interp_bz2.py > @@ -446,7 +446,9 @@ > result = self.buffer[pos:pos + n] > self.pos += n > else: > - result = self.buffer > + pos = self.pos > + assert pos >= 0 > + result = self.buffer[pos:] > self.pos = 0 > self.buffer = "" > self.readlength += len(result) > _______________________________________________ > pypy-commit mailing list > pypy-com...@python.org > http://mail.python.org/mailman/listinfo/pypy-commit >
This should come with a test _______________________________________________ pypy-dev mailing list pypy-dev@python.org http://mail.python.org/mailman/listinfo/pypy-dev