libidav/xml.c

changeset 818
bc782cca0759
parent 816
839fefbdedc7
--- a/libidav/xml.c	Thu May 23 23:19:06 2024 +0200
+++ b/libidav/xml.c	Thu May 23 23:23:36 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