From: Frank M. Kromann Date: Wed, 13 Jan 2010 07:26:08 +0000 (+0000) Subject: MFB. Don't free soap_headers just before comparing the length. This causes SoapClient... X-Git-Tag: php-5.2.13RC1~34 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=68414f081cdf403948136b52b349ab4d5d14781f;p=php MFB. Don't free soap_headers just before comparing the length. This causes SoapClient to fail when requesting a URL --- diff --git a/ext/soap/php_http.c b/ext/soap/php_http.c index dd0a6d856a..3797215393 100644 --- a/ext/soap/php_http.c +++ b/ext/soap/php_http.c @@ -709,7 +709,6 @@ try_again: smart_str_0(&soap_headers); err = php_stream_write(stream, soap_headers.c, soap_headers.len); - smart_str_free(&soap_headers); if (err != soap_headers.len) { if (request != buf) {efree(request);} php_stream_close(stream); @@ -720,6 +719,7 @@ try_again: smart_str_free(&soap_headers_z); return FALSE; } + smart_str_free(&soap_headers); } else { add_soap_fault(this_ptr, "HTTP", "Failed to create stream??", NULL, NULL TSRMLS_CC); smart_str_free(&soap_headers_z);