[pypy-commit] pypy py3.5-bz2-lzma: issue in bz2, data not appended

plan_rich pypy.commits at gmail.com
Wed Sep 28 10:15:49 EDT 2016


Author: Richard Plangger <planrichi at gmail.com>
Branch: py3.5-bz2-lzma
Changeset: r87434:87e7a5ea092e
Date: 2016-09-28 16:13 +0200
http://bitbucket.org/pypy/pypy/changeset/87e7a5ea092e/

Log:	issue in bz2, data not appended

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
@@ -479,7 +479,9 @@
         datalen = len(data)
         if len(self.input_buffer) > 0:
             input_buffer_in_use = True
-            result = self._decompress_buf(self.input_buffer, max_length)
+            data = self.input_buffer + data
+            datalen = len(data)
+            result = self._decompress_buf(data, max_length)
         else:
             input_buffer_in_use = False
             self.left_to_process = datalen


More information about the pypy-commit mailing list