[asterisk-commits] eliel: branch eliel/data_retrieval r189082 - in /team/eliel/data_retrieval: i...
SVN commits to the Asterisk project
asterisk-commits at lists.digium.com
Fri Apr 17 14:59:48 CDT 2009
Author: eliel
Date: Fri Apr 17 14:59:45 2009
New Revision: 189082
URL: http://svn.digium.com/svn-view/asterisk?view=rev&rev=189082
Log:
Implement a way to free the allocated ast_data_node result structure.
Modified:
team/eliel/data_retrieval/include/asterisk/data.h
team/eliel/data_retrieval/main/data.c
Modified: team/eliel/data_retrieval/include/asterisk/data.h
URL: http://svn.digium.com/svn-view/asterisk/team/eliel/data_retrieval/include/asterisk/data.h?view=diff&rev=189082&r1=189081&r2=189082
==============================================================================
--- team/eliel/data_retrieval/include/asterisk/data.h (original)
+++ team/eliel/data_retrieval/include/asterisk/data.h Fri Apr 17 14:59:45 2009
@@ -164,6 +164,13 @@
struct ast_data_node *ast_data_result(const char *name);
/*!
+ * \brief Free the result structure allocated calling ast_data_result.
+ * \param[in] handler The allocated result structure.
+ * \see ast_data_result
+ */
+void ast_data_result_free(struct ast_data_node *result_handler);
+
+/*!
* \brief Insert a node named 'path' with the string value 'value'.
* \param[in] handler The result handler.
* \param[in] path The path of the node to insert.
Modified: team/eliel/data_retrieval/main/data.c
URL: http://svn.digium.com/svn-view/asterisk/team/eliel/data_retrieval/main/data.c?view=diff&rev=189082&r1=189081&r2=189082
==============================================================================
--- team/eliel/data_retrieval/main/data.c (original)
+++ team/eliel/data_retrieval/main/data.c Fri Apr 17 14:59:45 2009
@@ -706,6 +706,11 @@
return (struct ast_data_node *) node;
}
+void ast_data_result_free(struct ast_data_node *result_handler)
+{
+ ast_xml_free_node((struct ast_xml_node *) result_handler);
+}
+
int ast_data_insert_str(struct ast_data_node *handler, const char *path, const char *value)
{
struct ast_xml_node *node;
More information about the asterisk-commits
mailing list