]> granicus.if.org Git - python/commitdiff
Fix incorrect comment in zlib.Decompress.flush().
authorNadeem Vawda <nadeem.vawda@gmail.com>
Sat, 13 Aug 2011 13:42:50 +0000 (15:42 +0200)
committerNadeem Vawda <nadeem.vawda@gmail.com>
Sat, 13 Aug 2011 13:42:50 +0000 (15:42 +0200)
Reported by Oleg Oshmyan in issue #12646.

Modules/zlibmodule.c

index dc707ff6cfc6f22a2827ad6fb880ea861c3f2914..711004e63f94ba74ec68a6175f9bf4294e2bb9f8 100644 (file)
@@ -886,9 +886,7 @@ PyZlib_unflush(compobject *self, PyObject *args)
         Py_END_ALLOW_THREADS
     }
 
-    /* If flushmode is Z_FINISH, we also have to call deflateEnd() to free
-       various data structures. Note we should only get Z_STREAM_END when
-       flushmode is Z_FINISH */
+    /* If at end of stream, clean up any memory allocated by zlib. */
     if (err == Z_STREAM_END) {
         self->eof = 1;
         self->is_initialised = 0;