diff options
author | Andrew Tridgell <tridge@samba.org> | 2005-01-02 07:51:13 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 13:07:55 -0500 |
commit | 500d5523d2a83234d6bfbf264d78293426488bfc (patch) | |
tree | 2a90456d248fb4c27184771ac2ede645356e6025 /source4/rpc_server/common/gendb.c | |
parent | 1a988ec9af7960616fb4661b20d86ff05146d836 (diff) | |
download | samba-500d5523d2a83234d6bfbf264d78293426488bfc.tar.gz samba-500d5523d2a83234d6bfbf264d78293426488bfc.tar.bz2 samba-500d5523d2a83234d6bfbf264d78293426488bfc.zip |
r4475: fixed smbd to work with the small changes in the ldb API (the most important
change was in the ldb_msg_add_*() routines, which now use the msg as a context,
and thus it needs to be a talloc ptr)
(This used to be commit 1a4713bfd0e519f3eb7b3241121ff914a6eeef18)
Diffstat (limited to 'source4/rpc_server/common/gendb.c')
-rw-r--r-- | source4/rpc_server/common/gendb.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/source4/rpc_server/common/gendb.c b/source4/rpc_server/common/gendb.c index 2aea42787a..bca1b823c2 100644 --- a/source4/rpc_server/common/gendb.c +++ b/source4/rpc_server/common/gendb.c @@ -43,10 +43,12 @@ int gendb_search_v(struct ldb_context *ldb, return -1; } - ldb_set_alloc(ldb, talloc_realloc_fn, mem_ctx); + *res = NULL; count = ldb_search(ldb, basedn, LDB_SCOPE_SUBTREE, expr, attrs, res); + if (*res) talloc_steal(mem_ctx, *res); + DEBUG(4,("gendb_search_v: %s %s -> %d (%s)\n", basedn?basedn:"NULL", expr, count, count==-1?ldb_errstring(ldb):"OK")); |