1
0
mirror of https://gitlab.gnome.org/GNOME/libxml2.git synced 2025-10-23 01:52:48 +03:00

tree: Allocate XML namespace statically

This commit is contained in:
Nick Wellnhofer
2024-03-04 07:34:25 +01:00
parent 696faeb474
commit 2840e33c5e
7 changed files with 86 additions and 215 deletions

View File

@@ -68,14 +68,14 @@ testBalancedChunk(void) {
int err = 0;
ret = xmlParseBalancedChunkMemory(NULL, NULL, NULL, 0,
BAD_CAST "start <node xml:lang='en'>abc</node> end", &list);
BAD_CAST "start <xml:node>abc</xml:node> end", &list);
if ((ret != XML_ERR_OK) ||
(list == NULL) ||
((elem = list->next) == NULL) ||
(elem->type != XML_ELEMENT_NODE) ||
(elem->nsDef == NULL) ||
(!xmlStrEqual(elem->nsDef->href, XML_XML_NAMESPACE))) {
(elem->ns == NULL) ||
(!xmlStrEqual(elem->ns->href, XML_XML_NAMESPACE))) {
fprintf(stderr, "xmlParseBalancedChunkMemory failed\n");
err = 1;
}