8000 ext/soap: Replace single usage of CHECK_XML_NULL with FIND_XML_NULL (… · php/php-src@407c978 · GitHub
[go: up one dir, main page]

Skip to content

Commit 407c978

Browse files
authored
ext/soap: Replace single usage of CHECK_XML_NULL with FIND_XML_NULL (#18698)
This removes the implicit assumption about the variable name of the zval Moreover, nearby the FIND_XML_NULL macro is used anyway.
1 parent fdebad0 commit 407c978

File tree

1 file changed

+1
-17
lines changed

1 file changed

+1
-17
lines changed

ext/soap/php_encoding.c

Lines changed: 1 addition & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -112,22 +112,6 @@ static void set_ns_and_type(xmlNodePtr node, encodeTypePtr type);
112112
} \
113113
}
114114

115-
#define CHECK_XML_NULL(xml) \
116-
{ \
117-
xmlAttrPtr null; \
118-
if (!xml) { \
119-
ZVAL_NULL(ret); \
120-
return ret; \
121-
} \
122-
if (xml->properties) { \
123-
null = get_attribute(xml->properties, "nil"); \
124-
if (null) { \
125-
ZVAL_NULL(ret); \
126-
return ret; \
127-
} \
128-
} \
129-
}
130-
131115
#define FIND_ZVAL_NULL(zval, xml, style) \
132116
{ \
133117
if (!zval || Z_TYPE_P(zval) == IS_NULL) { \
@@ -1480,7 +1464,7 @@ static zval *to_zval_object_ex(zval *ret, encodeTypePtr type, xmlNodePtr data, z
14801464
sdlType->encode->details.sdl_type->kind != XSD_TYPEKIND_LIST &&
14811465
sdlType->encode->details.sdl_type->kind != XSD_TYPEKIND_UNION) {
14821466

1483-
CHECK_XML_NUL 4E64 L(data);
1467+
FIND_XML_NULL(data, ret);
14841468
if (soap_check_xml_ref(ret, data)) {
14851469
return ret;
14861470
}

0 commit comments

Comments
 (0)
0