Skip to content

Commit e648d39

Browse files
authored
libxml set error structure simplification proposal (#12054)
1 parent 58ae26a commit e648d39

File tree

1 file changed

+1
-11
lines changed

1 file changed

+1
-11
lines changed

ext/libxml/libxml.c

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -609,19 +609,9 @@ static void _php_list_set_error_structure(xmlErrorPtr error, const char *msg)
609609
if (error) {
610610
ret = xmlCopyError(error, &error_copy);
611611
} else {
612-
error_copy.domain = 0;
613612
error_copy.code = XML_ERR_INTERNAL_ERROR;
614613
error_copy.level = XML_ERR_ERROR;
615-
error_copy.line = 0;
616-
error_copy.node = NULL;
617-
error_copy.int1 = 0;
618-
error_copy.int2 = 0;
619-
error_copy.ctxt = NULL;
620-
error_copy.message = (char*)xmlStrdup((xmlChar*)msg);
621-
error_copy.file = NULL;
622-
error_copy.str1 = NULL;
623-
error_copy.str2 = NULL;
624-
error_copy.str3 = NULL;
614+
error_copy.message = (char*)xmlStrdup((const xmlChar*)msg);
625615
ret = 0;
626616
}
627617

0 commit comments

Comments
 (0)