svn commit: samba r20033 - in branches/SAMBA_4_0/source/lib/ldb/common: .

idra at samba.org idra at samba.org
Tue Dec 5 03:52:58 GMT 2006


Author: idra
Date: 2006-12-05 03:52:58 +0000 (Tue, 05 Dec 2006)
New Revision: 20033

WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=20033

Log:

Never commit before testing
Never commit before testing
Never commit before testing

:-)



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-12-05 02:48:58 UTC (rev 20032)
+++ branches/SAMBA_4_0/source/lib/ldb/common/ldb.c	2006-12-05 03:52:58 UTC (rev 20033)
@@ -803,11 +803,12 @@
                         struct ldb_dn *base, enum ldb_scope scope, const char * const *attrs,
                         const char *exp_fmt, ...)
 {
-	struct ldb_result **res;
+	struct ldb_result *res;
 	char *expression;
 	va_list ap;
 	int ret;
 
+	res = NULL;
 	*result = NULL;
 
 	va_start(ap, exp_fmt);
@@ -818,11 +819,13 @@
 		return LDB_ERR_OPERATIONS_ERROR;
 	}
 
-	ret = ldb_search(ldb, base, scope, expression, attrs, res);
+	ret = ldb_search(ldb, base, scope, expression, attrs, &res);
 
 	if (ret == LDB_SUCCESS) {
 		talloc_steal(mem_ctx, res);
-		result = res;
+		*result = res;
+	} else {
+		talloc_free(res);
 	}
 
 	talloc_free(expression);



More information about the samba-cvs mailing list