From: Zeev Suraski Date: Thu, 16 Aug 2001 23:34:25 +0000 (+0000) Subject: Send Content-Length if we're sending just one chunk X-Git-Tag: PRE_SUBST_Z_MACROS~488 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=e9da242ed4654d99a909993e6919c37f7fbca9f3;p=php Send Content-Length if we're sending just one chunk --- diff --git a/ext/zlib/CREDITS b/ext/zlib/CREDITS index 4972838339..c0a47dd293 100644 --- a/ext/zlib/CREDITS +++ b/ext/zlib/CREDITS @@ -1,2 +1,2 @@ Zlib -Rasmus Lerdorf, Stefan Roehrich +Rasmus Lerdorf, Stefan Roehrich, Zeev Suraski, Jade Nicoletti diff --git a/ext/zlib/zlib.c b/ext/zlib/zlib.c index 72a4680fe8..b331bad23a 100644 --- a/ext/zlib/zlib.c +++ b/ext/zlib/zlib.c @@ -14,6 +14,8 @@ +----------------------------------------------------------------------+ | Authors: Rasmus Lerdorf | | Stefan Röhrich | + | Zeev Suraski | + | Jade Nicoletti | +----------------------------------------------------------------------+ */ /* $Id$ */ @@ -1200,13 +1202,11 @@ PHP_FUNCTION(ob_gzhandler) if (return_original) { zval_dtor(return_value); -#if 0 - } else { + } else if (do_start && do_end) { char lenbuf[64]; sprintf(lenbuf,"Content-Length: %d",Z_STRLEN_P(return_value)); sapi_add_header(lenbuf,strlen(lenbuf), 1); -#endif } } else { return_original = 1;