libidav/xml.c

changeset 49
2f71f4ee247a
parent 1
b5bb7b3cd597
--- a/libidav/xml.c	Thu Oct 03 18:52:51 2024 +0200
+++ b/libidav/xml.c	Sun Oct 06 18:18:04 2024 +0200
@@ -72,7 +72,7 @@
     
     DavXmlNode *ret = NULL;
     
-    while(stack->size > 0) {
+    while(cxListSize(stack) > 0) {
         ConvXmlElm *c = cxListAt(stack, 0);
         xmlNode *n = c->node;
         DavXmlNode *c_parent = c->parent;
@@ -173,7 +173,7 @@
             if(node->namespace) {
                 prefix = cxMapGet(nsmap, cx_hash_key_str(node->namespace));
                 if(!prefix) {
-                    cxmutstr newpre = cx_asprintf("x%d", (int)nsmap->size+1);
+                    cxmutstr newpre = cx_asprintf("x%zu", cxMapSize(nsmap)+1);
                     // TODO: fix namespace declaration
                     //ucx_map_cstr_put(nsmap, node->namespace, newpre.ptr);
                     prefix = newpre.ptr;

mercurial