From 22f473b22bc2b2aae2b53a180b78c2e891ab956e Mon Sep 17 00:00:00 2001 From: Stefan Metzmacher Date: Sun, 7 Jan 2007 19:04:40 +0000 Subject: r20598: add comments and make clear that the void *data element for extended operations needs to be NULL or a valid talloc pointer as talloc_get_type() will be called on it. metze (This used to be commit 5731617ea9103eaaef2c5591aab89d59ded35fd8) --- source4/lib/ldb/include/ldb.h | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) (limited to 'source4/lib') diff --git a/source4/lib/ldb/include/ldb.h b/source4/lib/ldb/include/ldb.h index 7b37b50468..62afbfb609 100644 --- a/source4/lib/ldb/include/ldb.h +++ b/source4/lib/ldb/include/ldb.h @@ -676,7 +676,7 @@ enum ldb_state { struct ldb_extended { const char *oid; - void *data; + void *data; /* NULL or a valid talloc pointer! talloc_get_type() will be used on it */ }; struct ldb_result { @@ -1118,7 +1118,8 @@ int ldb_extended_default_callback(struct ldb_context *ldb, void *context, struct \param ldb the context associated with the database (from ldb_init()) \param mem_ctx a talloc emmory context (used as parent of ret_req) \param oid the OID of the extended operation. - \param data void pointer a the extended operation specific parameters + \param data a void pointer a the extended operation specific parameters, + it needs to be NULL or a valid talloc pointer! talloc_get_type() will be used on it \param controls an array of controls \param context the callback function context \param the callback function to handle the async replies @@ -1129,7 +1130,7 @@ int ldb_build_extended_req(struct ldb_request **ret_req, struct ldb_context *ldb, void *mem_ctx, const char *oid, - void *data, + void *data,/* NULL or a valid talloc pointer! talloc_get_type() will be used on it */ struct ldb_control **controls, void *context, ldb_request_callback_t callback); @@ -1141,7 +1142,8 @@ int ldb_build_extended_req(struct ldb_request **ret_req, \param ldb the context associated with the database (from ldb_init()) \param oid the OID of the extended operation. - \param data void pointer a the extended operation specific parameters + \param data a void pointer a the extended operation specific parameters, + it needs to be NULL or a valid talloc pointer! talloc_get_type() will be used on it \param res the result of the extended operation \return result code (LDB_SUCCESS if the extended operation returned fine, @@ -1149,7 +1151,7 @@ int ldb_build_extended_req(struct ldb_request **ret_req, */ int ldb_extended(struct ldb_context *ldb, const char *oid, - void *data, + void *data,/* NULL or a valid talloc pointer! talloc_get_type() will be used on it */ struct ldb_result **res); /** -- cgit