git.samba.org
/
mat
/
samba.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6c72674
)
s4:dsdb Allow a NULL search expression in dsdb_search()
author
Andrew Bartlett
<abartlet@samba.org>
Thu, 20 May 2010 22:11:13 +0000
(08:11 +1000)
committer
Andrew Bartlett
<abartlet@samba.org>
Mon, 24 May 2010 13:08:11 +0000
(23:08 +1000)
The NULL search expression expands to (objectClass=*), but %s expands
NULL to (NULL) which doesn't parse...
Andrew Bartlett
source4/dsdb/common/util.c
patch
|
blob
|
history
diff --git
a/source4/dsdb/common/util.c
b/source4/dsdb/common/util.c
index da4d0b39402519126273fb45768c5c6d5160c1c9..987864f74830c76584db602c384d1ec53e631e19 100644
(file)
--- a/
source4/dsdb/common/util.c
+++ b/
source4/dsdb/common/util.c
@@
-3641,10
+3641,13
@@
int dsdb_search_one(struct ldb_context *ldb,
talloc_free(tmp_ctx);
return LDB_ERR_OPERATIONS_ERROR;
}
+ ret = dsdb_search(ldb, tmp_ctx, &res, basedn, scope, attrs,
+ dsdb_flags, "%s", expression);
+ } else {
+ ret = dsdb_search(ldb, tmp_ctx, &res, basedn, scope, attrs,
+ dsdb_flags, NULL);
}
- ret = dsdb_search(ldb, tmp_ctx, &res, basedn, scope, attrs,
- dsdb_flags, "%s", expression);
if (ret != LDB_SUCCESS) {
talloc_free(tmp_ctx);
return ret;