diff options
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 b606030179..18a266179b 100644 --- a/ext/soap/php_xml.c +++ b/ext/soap/php_xml.c @@ -199,7 +199,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) { @@ -215,7 +215,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) { |