libidav/xml.c

changeset 818
bc782cca0759
parent 816
839fefbdedc7
equal deleted inserted replaced
817:22257f6d06a3 818:bc782cca0759
70 } 70 }
71 cxListInsert(stack, 0, &ce); 71 cxListInsert(stack, 0, &ce);
72 72
73 DavXmlNode *ret = NULL; 73 DavXmlNode *ret = NULL;
74 74
75 while(stack->size > 0) { 75 while(cxListSize(stack) > 0) {
76 ConvXmlElm *c = cxListAt(stack, 0); 76 ConvXmlElm *c = cxListAt(stack, 0);
77 xmlNode *n = c->node; 77 xmlNode *n = c->node;
78 DavXmlNode *c_parent = c->parent; 78 DavXmlNode *c_parent = c->parent;
79 DavXmlNode *prev = NULL; 79 DavXmlNode *prev = NULL;
80 cxListRemove(stack, 0); 80 cxListRemove(stack, 0);
171 char *prefix = NULL; 171 char *prefix = NULL;
172 char *prefix_fr = NULL; 172 char *prefix_fr = NULL;
173 if(node->namespace) { 173 if(node->namespace) {
174 prefix = cxMapGet(nsmap, cx_hash_key_str(node->namespace)); 174 prefix = cxMapGet(nsmap, cx_hash_key_str(node->namespace));
175 if(!prefix) { 175 if(!prefix) {
176 cxmutstr newpre = cx_asprintf("x%d", (int)nsmap->size+1); 176 cxmutstr newpre = cx_asprintf("x%zu", cxMapSize(nsmap)+1);
177 // TODO: fix namespace declaration 177 // TODO: fix namespace declaration
178 //ucx_map_cstr_put(nsmap, node->namespace, newpre.ptr); 178 //ucx_map_cstr_put(nsmap, node->namespace, newpre.ptr);
179 prefix = newpre.ptr; 179 prefix = newpre.ptr;
180 prefix_fr = prefix; 180 prefix_fr = prefix;
181 cx_fprintf( 181 cx_fprintf(

mercurial