Skip to content

Commit 9f5325f

Browse files
committed
Attempt to fix _Pragma error on older gcc versions
1 parent 14fbb44 commit 9f5325f

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

ext/soap/php_encoding.c

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2387,8 +2387,9 @@ static xmlNodePtr to_xml_array(encodeTypePtr type, zval *data, int style, xmlNod
23872387
if (soap_version == SOAP_1_1) {
23882388
smart_str_0(&array_type);
23892389
ZEND_CGG_DIAGNOSTIC_IGNORED_START("-Wstringop-overread")
2390-
if (strcmp(ZSTR_VAL(array_type.s),"xsd:anyType") == 0) {
2391-
ZEND_CGG_DIAGNOSTIC_IGNORED_END
2390+
bool isXsdAnyType = strcmp(ZSTR_VAL(array_type.s),"xsd:anyType") == 0;
2391+
ZEND_CGG_DIAGNOSTIC_IGNORED_END
2392+
if (isXsdAnyType) {
23922393
smart_str_free(&array_type);
23932394
smart_str_appendl(&array_type,"xsd:ur-type",sizeof("xsd:ur-type")-1);
23942395
}

0 commit comments

Comments
 (0)