fix http_exit_ex when zlib output compression is active
authorMichael Wallner <mike@php.net>
Thu, 24 Mar 2011 09:53:35 +0000 (09:53 +0000)
committerMichael Wallner <mike@php.net>
Thu, 24 Mar 2011 09:53:35 +0000 (09:53 +0000)
http_api.c

index aca90e669f5adeed209212cb1fbbc86bb34827e1..4f1b7e387e9b6283d2d2c41bc459d02a39bae645 100644 (file)
@@ -253,7 +253,7 @@ STATUS _http_exit_ex(int status, char *header, char *body, zend_bool send_header
                return FAILURE;
        }
        
-       if (!OG(ob_lock)) {
+       if (!php_ob_handler_used("zlib output compression") && !php_ob_handler_used("ob_gzhandler") && !OG(ob_lock)) {
                php_end_ob_buffers(0 TSRMLS_CC);
        }
        if ((SUCCESS == sapi_send_headers(TSRMLS_C)) && body) {