# HG changeset patch # User Paul Aurich # Date 1278723371 0 # Node ID 77cd42f08ba111cb0df29a2a827bb7666c1f13eb # Parent 067ad74c7523b536f8944663230fe4f98eb62a09 const-ify the xmlnode* parameter to xmlnode_get_attrib(_with_namespace) This doesn't break A[BP]I, right? It seems sane to me and is needed for my next commit (using const xmlnode*s) diff -r 067ad74c7523 -r 77cd42f08ba1 libpurple/xmlnode.c --- a/libpurple/xmlnode.c Sat Jul 10 00:35:52 2010 +0000 +++ b/libpurple/xmlnode.c Sat Jul 10 00:56:11 2010 +0000 @@ -223,7 +223,7 @@ const char * -xmlnode_get_attrib(xmlnode *node, const char *attr) +xmlnode_get_attrib(const xmlnode *node, const char *attr) { xmlnode *x; @@ -240,9 +240,9 @@ } const char * -xmlnode_get_attrib_with_namespace(xmlnode *node, const char *attr, const char *xmlns) +xmlnode_get_attrib_with_namespace(const xmlnode *node, const char *attr, const char *xmlns) { - xmlnode *x; + const xmlnode *x; g_return_val_if_fail(node != NULL, NULL); g_return_val_if_fail(attr != NULL, NULL); diff -r 067ad74c7523 -r 77cd42f08ba1 libpurple/xmlnode.h --- a/libpurple/xmlnode.h Sat Jul 10 00:35:52 2010 +0000 +++ b/libpurple/xmlnode.h Sat Jul 10 00:56:11 2010 +0000 @@ -205,7 +205,7 @@ * * @return The value of the attribute. */ -const char *xmlnode_get_attrib(xmlnode *node, const char *attr); +const char *xmlnode_get_attrib(const xmlnode *node, const char *attr); /** * Gets a namespaced attribute from a node @@ -216,7 +216,7 @@ * * @return The value of the attribute/ */ -const char *xmlnode_get_attrib_with_namespace(xmlnode *node, const char *attr, const char *xmlns); +const char *xmlnode_get_attrib_with_namespace(const xmlnode *node, const char *attr, const char *xmlns); /** * Removes an attribute from a node.