Skip to content

Commit 7725ed2

Browse files
authored
fix serialization segfault
1 parent 307b963 commit 7725ed2

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

source/myhtml/serialization.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -149,13 +149,13 @@ mystatus_t myhtml_serialization_node_callback(myhtml_tree_node_t* node, mycore_c
149149

150150
attr = attr->next;
151151

152-
if (attr) {
152+
if(attr) {
153153
myhtml_tree_attr_t *system_id = NULL, *public_id = NULL;
154154

155-
if (attr->value.length == 6) {
156-
if (mycore_strcasecmp(attr->value.data, "SYSTEM") == 0) {
155+
if(attr->value.length == 6) {
156+
if(mycore_strcasecmp(attr->value.data, "SYSTEM") == 0) {
157157
system_id = attr->next;
158-
} else if (mycore_strcasecmp(attr->value.data, "PUBLIC") == 0) {
158+
} else if(mycore_strcasecmp(attr->value.data, "PUBLIC") == 0) {
159159
public_id = attr->next;
160160
system_id = public_id ? public_id->next : NULL;
161161
}

0 commit comments

Comments
 (0)