Author: Julian Berman <julian...@grayvines.com> Branch: zlib-copying-third-time-a-charm Changeset: r95879:4ae1b51c0133 Date: 2019-02-07 07:53 +0100 http://bitbucket.org/pypy/pypy/changeset/4ae1b51c0133/
Log: Immediately free the z_stream after flushing a decompressobj. Matches what CPython does, and doesn't wait for the finalizer, but more importantly will help us actually pass the lib-python test in a minute... diff --git a/pypy/module/zlib/interp_zlib.py b/pypy/module/zlib/interp_zlib.py --- a/pypy/module/zlib/interp_zlib.py +++ b/pypy/module/zlib/interp_zlib.py @@ -359,6 +359,9 @@ else: string, finished, unused_len = result self._save_unconsumed_input(data, finished, unused_len) + if finished: + rzlib.inflateEnd(self.stream) + self.stream = rzlib.null_stream return space.newbytes(string) _______________________________________________ pypy-commit mailing list pypy-commit@python.org https://mail.python.org/mailman/listinfo/pypy-commit