From f8b17453289061baee75586df671c62e9cd120e1 Mon Sep 17 00:00:00 2001 From: Michael Wallner Date: Wed, 14 Sep 2016 12:55:43 +0200 Subject: [PATCH] coverity fix --- src/php_http_encoding.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/src/php_http_encoding.c b/src/php_http_encoding.c index 8c29216..b5094ee 100644 --- a/src/php_http_encoding.c +++ b/src/php_http_encoding.c @@ -265,10 +265,9 @@ php_http_encoding_stream_t *php_http_encoding_stream_copy(php_http_encoding_stre TSRMLS_FETCH_FROM_CTX(from->ts); if (from->ops->copy) { - int freeme; php_http_encoding_stream_t *ns; - if ((freeme = !to)) { + if (!to) { to = pemalloc(sizeof(*to), (from->flags & PHP_HTTP_ENCODING_STREAM_PERSISTENT)); } memset(to, 0, sizeof(*to)); @@ -282,10 +281,6 @@ php_http_encoding_stream_t *php_http_encoding_stream_copy(php_http_encoding_stre } else { return to; } - - if (freeme) { - pefree(to, (to->flags & PHP_HTTP_ENCODING_STREAM_PERSISTENT)); - } } return NULL; -- 2.30.2