diff options
author | Stanislav Malyshev <stas@php.net> | 2021-01-31 21:42:48 -0800 |
---|---|---|
committer | Stanislav Malyshev <stas@php.net> | 2021-01-31 21:42:48 -0800 |
commit | d94d0dda297ebc2f7afe0add2a6f85ddd057b4ee (patch) | |
tree | 0bcaeb2a375b0c8ceba6b949a6df2427370f014c /ext/soap/php_xml.c | |
parent | 49ef8bc0267d551ea3a8698213a82f0b7eb0a297 (diff) | |
parent | 86de4d7af6d8bf6aa2955b158a12272f76ceb97e (diff) | |
download | php-git-d94d0dda297ebc2f7afe0add2a6f85ddd057b4ee.tar.gz |
Merge branch 'PHP-7.4' into PHP-8.0
* PHP-7.4:
Fix bug #80672 - Null Dereference in SoapClient
Diffstat (limited to 'ext/soap/php_xml.c')
-rw-r--r-- | ext/soap/php_xml.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ext/soap/php_xml.c b/ext/soap/php_xml.c index df55678159..e290786f7a 100644 --- a/ext/soap/php_xml.c +++ b/ext/soap/php_xml.c @@ -197,7 +197,7 @@ xmlNsPtr node_find_ns(xmlNodePtr node) int attr_is_equal_ex(xmlAttrPtr node, char *name, char *ns) { - if (name == NULL || strcmp((char*)node->name, name) == 0) { + if (name == NULL || ((node->name) && strcmp((char*)node->name, name) == 0)) { if (ns) { xmlNsPtr nsPtr = attr_find_ns(node); if (nsPtr) { @@ -213,7 +213,7 @@ int attr_is_equal_ex(xmlAttrPtr node, char *name, char *ns) int node_is_equal_ex(xmlNodePtr node, char *name, char *ns) { - if (name == NULL || strcmp((char*)node->name, name) == 0) { + if (name == NULL || ((node->name) && strcmp((char*)node->name, name) == 0)) { if (ns) { xmlNsPtr nsPtr = node_find_ns(node); if (nsPtr) { |