# HG changeset patch # User Daniel Atallah # Date 1159306657 0 # Node ID 58202142e9ad2d37ff4d5e2e1c99fbab2476c887 # Parent 134f4d999ff0523e71d7562fc2a2ebc4753f6f86 [gaim-migrate @ 17369] This is what we decided to do about the signedness warnings, right? committer: Tailor Script diff -r 134f4d999ff0 -r 58202142e9ad libgaim/protocols/jabber/parser.c --- a/libgaim/protocols/jabber/parser.c Tue Sep 26 20:07:02 2006 +0000 +++ b/libgaim/protocols/jabber/parser.c Tue Sep 26 21:37:37 2006 +0000 @@ -40,7 +40,7 @@ if(!element_name) { return; - } else if(!strcmp(element_name, "stream")) { + } else if(!xmlStrcmp(element_name, (xmlChar*) "stream")) { js->protocol_version = JABBER_PROTO_0_9; for(i=0; i < nb_attributes * 5; i += 5) { int attrib_len = attributes[i+4] - attributes[i+3]; @@ -48,11 +48,11 @@ memcpy(attrib, attributes[i+3], attrib_len); attrib[attrib_len] = '\0'; - if(!strcmp(attributes[i], "version") + if(!xmlStrcmp(attributes[i], (xmlChar*) "version") && !strcmp(attrib, "1.0")) { js->protocol_version = JABBER_PROTO_1_0; g_free(attrib); - } else if(!strcmp(attributes[i], "id")) { + } else if(!xmlStrcmp(attributes[i], (xmlChar*) "id")) { if(js->stream_id) g_free(js->stream_id); js->stream_id = attrib; @@ -66,17 +66,17 @@ } else { if(js->current) - node = xmlnode_new_child(js->current, element_name); + node = xmlnode_new_child(js->current, (const char*) element_name); else - node = xmlnode_new(element_name); - xmlnode_set_namespace(node, namespace); + node = xmlnode_new((const char*) element_name); + xmlnode_set_namespace(node, (const char*) namespace); for(i=0; i < nb_attributes * 5; i+=5) { int attrib_len = attributes[i+4] - attributes[i+3]; char *attrib = g_malloc(attrib_len + 1); memcpy(attrib, attributes[i+3], attrib_len); attrib[attrib_len] = '\0'; - xmlnode_set_attrib(node, attributes[i], attrib); + xmlnode_set_attrib(node, (const char*) attributes[i], attrib); g_free(attrib); } @@ -94,7 +94,7 @@ return; if(js->current->parent) { - if(!strcmp(js->current->name, element_name)) + if(!xmlStrcmp((xmlChar*) js->current->name, element_name)) js->current = js->current->parent; } else { xmlnode *packet = js->current; @@ -115,7 +115,7 @@ if(!text || !text_len) return; - xmlnode_insert_data(js->current, text, text_len); + xmlnode_insert_data(js->current, (const char*) text, text_len); } static xmlSAXHandler jabber_parser_libxml = { diff -r 134f4d999ff0 -r 58202142e9ad libgaim/xmlnode.c --- a/libgaim/xmlnode.c Tue Sep 26 20:07:02 2006 +0000 +++ b/libgaim/xmlnode.c Tue Sep 26 21:37:37 2006 +0000 @@ -386,11 +386,11 @@ return; } else { if(xpd->current) - node = xmlnode_new_child(xpd->current, element_name); + node = xmlnode_new_child(xpd->current, (const char*) element_name); else - node = xmlnode_new(element_name); + node = xmlnode_new((const char *) element_name); - xmlnode_set_namespace(node, namespace); + xmlnode_set_namespace(node, (const char *) namespace); for(i=0; i < nb_attributes * 5; i+=5) { char *txt; @@ -401,7 +401,7 @@ txt = attrib; attrib = gaim_unescape_html(txt); g_free(txt); - xmlnode_set_attrib(node, attributes[i], attrib); + xmlnode_set_attrib(node, (const char*) attributes[i], attrib); g_free(attrib); } @@ -419,7 +419,7 @@ return; if(xpd->current->parent) { - if(!strcmp(xpd->current->name, element_name)) + if(!xmlStrcmp((xmlChar*) xpd->current->name, element_name)) xpd->current = xpd->current->parent; } } @@ -435,7 +435,7 @@ if(!text || !text_len) return; - xmlnode_insert_data(xpd->current, text, text_len); + xmlnode_insert_data(xpd->current, (const char*) text, text_len); } static xmlSAXHandler xmlnode_parser_libxml = {