From: Ilia Alshanetsky Date: Wed, 24 Aug 2005 16:20:12 +0000 (+0000) Subject: MFH: Remainder of the 34191 bug fix. X-Git-Tag: php-4.4.1RC1~47 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=ca741c453e0466560ce2e2b07c4bf373a1d21ded;p=php MFH: Remainder of the 34191 bug fix. --- diff --git a/main/output.c b/main/output.c index bc3bf52627..969f1bf82e 100644 --- a/main/output.c +++ b/main/output.c @@ -296,6 +296,9 @@ PHPAPI void php_end_ob_buffer(zend_bool send_buffer, zend_bool just_flush TSRMLS OG(ob_nesting_level)--; if (send_buffer) { + if (just_flush) { /* if flush is called prior to proper end, ensure presence of NUL */ + final_buffer[final_buffer_length] = '\0'; + } OG(php_body_write)(final_buffer, final_buffer_length TSRMLS_CC); }