svn commit: samba r13900 - in
branches/SAMBA_4_0/source/lib/ldb/common: .
idra at samba.org
idra at samba.org
Mon Mar 6 21:40:48 GMT 2006
Author: idra
Date: 2006-03-06 21:40:47 +0000 (Mon, 06 Mar 2006)
New Revision: 13900
WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=13900
Log:
don't segfault on error
Modified:
branches/SAMBA_4_0/source/lib/ldb/common/ldb.c
Changeset:
Modified: branches/SAMBA_4_0/source/lib/ldb/common/ldb.c
===================================================================
--- branches/SAMBA_4_0/source/lib/ldb/common/ldb.c 2006-03-06 21:36:24 UTC (rev 13899)
+++ branches/SAMBA_4_0/source/lib/ldb/common/ldb.c 2006-03-06 21:40:47 UTC (rev 13900)
@@ -305,10 +305,10 @@
/* the search call is the only one that returns something
other than a status code. We steal the results into
the context of the ldb before freeing the request */
- if (request->operation == LDB_REQ_SEARCH) {
+ if (status == LDB_SUCCESS && request->operation == LDB_REQ_SEARCH) {
request->op.search.res = talloc_steal(ldb, r->op.search.res);
}
- if (request->operation == LDB_ASYNC_SEARCH) {
+ if (status == LDB_SUCCESS && request->operation == LDB_ASYNC_SEARCH) {
request->async.handle = r->async.handle;
}
talloc_free(r);
More information about the samba-cvs
mailing list