[asterisk-commits] mmichelson: branch group/CCSS r239230 - /team/group/CCSS/channels/chan_sip.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Mon Jan 11 16:53:21 CST 2010


Author: mmichelson
Date: Mon Jan 11 16:53:18 2010
New Revision: 239230

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=239230
Log:
Add more warning messages when parsing PIDF XML.


Modified:
    team/group/CCSS/channels/chan_sip.c

Modified: team/group/CCSS/channels/chan_sip.c
URL: http://svnview.digium.com/svn/asterisk/team/group/CCSS/channels/chan_sip.c?view=diff&rev=239230&r1=239229&r2=239230
==============================================================================
--- team/group/CCSS/channels/chan_sip.c (original)
+++ team/group/CCSS/channels/chan_sip.c Mon Jan 11 16:53:18 2010
@@ -23720,6 +23720,7 @@
 	struct ast_xml_node *tuple_children_iterator;
 	/* Tuples have to have an id attribute or they're invalid */
 	if (!(id = ast_xml_get_attribute(tuple_node, "id"))) {
+		ast_log(LOG_NOTICE, "Tuple XML element has no attribute 'id'\n");
 		return FALSE;
 	}
 	/* We don't care what it actually is, just that it's there */
@@ -23727,6 +23728,7 @@
 	/* This is a tuple. It must have a status element */
 	if (!(tuple_children = ast_xml_node_get_children(tuple_node))) {
 		/* The tuple has no children. It sucks */
+		ast_log(LOG_NOTICE, "Tuple XML element has no child elements\n");
 		return FALSE;
 	}
 	for (tuple_children_iterator = tuple_children; tuple_children_iterator;
@@ -23741,6 +23743,7 @@
 		}
 		if (status_found == TRUE) {
 			/* THERE CAN BE ONLY ONE!!! */
+			ast_log(LOG_NOTICE, "Multiple status elements found in tuple. Only one allowed\n");
 			return FALSE;
 		}
 		status_found = TRUE;




More information about the asterisk-commits mailing list