From: Michael Wallner Date: Mon, 15 Jun 2015 14:02:43 +0000 (+0200) Subject: fix leak X-Git-Tag: RELEASE_3_0_0_RC1~45 X-Git-Url: https://git.m6w6.name/?a=commitdiff_plain;h=5472eafc42e2a6c6baf8c2dbc009823ba55f6a66;p=m6w6%2Fext-http fix leak --- diff --git a/php_http_env_response.c b/php_http_env_response.c index 9f01814..2b633c1 100644 --- a/php_http_env_response.c +++ b/php_http_env_response.c @@ -1158,7 +1158,9 @@ static PHP_METHOD(HttpEnvResponse, __invoke) PHP_HTTP_ENV_RESPONSE_OBJECT_INIT(obj); - php_http_message_object_init_body_object(obj); + if (!obj->body) { + php_http_message_object_init_body_object(obj); + } if (ob_flags & PHP_OUTPUT_HANDLER_CLEAN) { php_stream_truncate_set_size(php_http_message_body_stream(obj->message->body), 0);