From d909a9f409849dfe4072f2f57fdd2349ca8a0a3c Mon Sep 17 00:00:00 2001 From: David Robillard Date: Mon, 30 Mar 2009 14:44:56 +0000 Subject: Fix memory leaks. Document ownership semantics of query value accessors. Fix test ccflags for new waf. git-svn-id: http://svn.drobilla.net/lad/trunk/slv2@1951 a436a847-0d15-0410-975c-d299462d15a1 --- slv2/query.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'slv2') diff --git a/slv2/query.h b/slv2/query.h index aa25436..0c9c943 100644 --- a/slv2/query.h +++ b/slv2/query.h @@ -54,6 +54,7 @@ slv2_results_finished(SLV2Results results); /** Return a binding in \a results by index. * Indices correspond to selected variables in the query in order of appearance. + * Returned value must be freed by caller with slv2_value_free. * \return NULL if binding value can not be expressed as an SLV2Value. */ SLV2Value @@ -62,6 +63,7 @@ slv2_results_get_binding_value(SLV2Results results, unsigned index); /** Return a binding in \a results by name. * \a name corresponds to the name of the SPARQL variable (without the '?'). + * Returned value must be freed by caller with slv2_value_free. * \return NULL if binding value can not be expressed as an SLV2Value. */ SLV2Value @@ -69,6 +71,7 @@ slv2_results_get_binding_value_by_name(SLV2Results results, const char* name); /** Return the name of a binding in \a results. + * Returned value is shared and must not be freed by caller. * Indices correspond to selected variables in the query in order of appearance. */ const char* -- cgit v1.2.1