adium: 484009ed: Don't set our own XML error handler.

zacw at adiumx.com zacw at adiumx.com
Sat May 23 23:30:38 EDT 2009


-----------------------------------------------------------------
Revision: 484009ed16ea5497dd8a49b1c25c8cdc049560ad
Ancestor: 064b7f3d1c27f2281afa9d9bc9a29656ec85cf9b
Author: zacw at adiumx.com
Date: 2009-05-24T03:27:54
Branch: im.pidgin.adium
URL: http://d.pidgin.im/viewmtn/revision/info/484009ed16ea5497dd8a49b1c25c8cdc049560ad

Modified files:
        libpurple/xmlnode.c

ChangeLog: 

Don't set our own XML error handler.

According to darkrain42, "[libpurple] now provide[s] such a handler via the sax2 struct for all parsers in libpurple, so it shouldn't be necessary anymore (in theory)".


-------------- next part --------------
============================================================
--- libpurple/xmlnode.c	b95e7c5f489abccba8055db71be6707acd442a81
+++ libpurple/xmlnode.c	ff037d9a540b18e1b48a43022e3cc6deb4055685
@@ -704,15 +704,6 @@ static xmlSAXHandler xmlnode_parser_libx
 	xmlnode_parser_structural_error_libxml, /* serror */
 };
 
-static void
-libpurple_parser_structured_error_handler(void *user_data, xmlErrorPtr error)
-{
-	purple_debug_error("xmlnode", "XML parser error: "
-					   "Domain %i, code %i, level %i: %s\n",
-					   error->domain, error->code, error->level,
-					   (error->message ? error->message : "(null)"));
-}
-
 xmlnode *
 xmlnode_from_str(const char *str, gssize size)
 {
@@ -725,8 +716,6 @@ xmlnode_from_str(const char *str, gssize
 	real_size = size < 0 ? strlen(str) : size;
 	xpd = g_new0(struct _xmlnode_parser_data, 1);
 
-	xmlSetStructuredErrorFunc(NULL, libpurple_parser_structured_error_handler);
-
 	if (xmlSAXUserParseMemory(&xmlnode_parser_libxml, xpd, str, real_size) < 0) {
 		while(xpd->current && xpd->current->parent)
 			xpd->current = xpd->current->parent;


More information about the Commits mailing list