com php-src: Check zpp before other errors in SoapServer::addSoapHeader(): ext/soap/soap.c

From: Date: Fri, 30 Aug 2019 15:03:25 +0000
Subject: com php-src: Check zpp before other errors in SoapServer::addSoapHeader(): ext/soap/soap.c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-108166@lists.php.net to get a copy of this message
Commit: ec9297592e30d5fe347bc4de21f01b2c4e04df54 Author: Nikita Popov <nikita.ppv@gmail.com> Fri, 30 Aug 2019 17:03:04 +0200 Parents: 82d9f145325f8bc52b1cbbc7fdf9cab46ea65a3f Branches: master Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=ec9297592e30d5fe347bc4de21f01b2c4e04df54 Log: Check zpp before other errors in SoapServer::addSoapHeader() Changed paths: M ext/soap/soap.c Diff: diff --git a/ext/soap/soap.c b/ext/soap/soap.c index 3f1e718..f0d836e 100644 --- a/ext/soap/soap.c +++ b/ext/soap/soap.c @@ -2012,6 +2012,10 @@ PHP_METHOD(SoapServer, addSoapHeader) SOAP_SERVER_BEGIN_CODE(); + if (zend_parse_parameters(ZEND_NUM_ARGS(), "O", &fault, soap_header_class_entry) == FAILURE) { + return; + } + FETCH_THIS_SERVICE(service); if (!service || !service->soap_headers_ptr) { @@ -2019,10 +2023,6 @@ PHP_METHOD(SoapServer, addSoapHeader) return; } - if (zend_parse_parameters(ZEND_NUM_ARGS(), "O", &fault, soap_header_class_entry) == FAILURE) { - return; - } - p = service->soap_headers_ptr; while (*p != NULL) { p = &(*p)->next;

« previous php.cvs (#108166) next »