]> granicus.if.org Git - php/commitdiff
Don't use streams-level buffer on zlib streams.
authorWez Furlong <wez@php.net>
Tue, 15 Oct 2002 02:27:15 +0000 (02:27 +0000)
committerWez Furlong <wez@php.net>
Tue, 15 Oct 2002 02:27:15 +0000 (02:27 +0000)
ext/zlib/zlib_fopen_wrapper.c

index b97f6a691bd8148847134974d61ead2cb6d2cef4..b7c5454a37029a1720474d15166420803039ece7 100644 (file)
@@ -111,8 +111,10 @@ php_stream *php_stream_gzopen(php_stream_wrapper *wrapper, char *path, char *mod
                        self->gz_file = gzdopen(fd, mode);
                        if (self->gz_file)      {
                                stream = php_stream_alloc_rel(&php_stream_gzio_ops, self, 0, mode);
-                               if (stream)
+                               if (stream) {
+                                       stream->flags |= PHP_STREAM_FLAG_NO_BUFFER;
                                        return stream;
+                               }
                                gzclose(self->gz_file);
                        }
                        if (options & REPORT_ERRORS)