From 3b6f181dd8b96bda5438f2ce7b9af266e4259330 Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Fri, 7 Oct 2005 11:55:53 +0000 Subject: [PATCH] Fixed bug #34766 (possible crash on HTTP redirection) --- ext/soap/php_http.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/ext/soap/php_http.c b/ext/soap/php_http.c index b9d6f49bf3..5680ae8dcb 100644 --- a/ext/soap/php_http.c +++ b/ext/soap/php_http.c @@ -836,6 +836,7 @@ try_again: php_stream_close(stream); zend_hash_del(Z_OBJPROP_P(this_ptr), "httpsocket", sizeof("httpsocket")); zend_hash_del(Z_OBJPROP_P(this_ptr), "_use_proxy", sizeof("_use_proxy")); + stream = NULL; } /* Process HTTP status codes */ @@ -848,13 +849,6 @@ try_again: int body_size; if (new_url != NULL) { - if (get_http_body(stream, !http_1_1, http_headers, &body, &body_size TSRMLS_CC)) { - efree(body); - } else { - php_stream_close(stream); - zend_hash_del(Z_OBJPROP_P(this_ptr), "httpsocket", sizeof("httpsocket")); - stream = NULL; - } efree(http_headers); efree(http_body); efree(loc); -- 2.40.0