From 508527890adc7bedd47522a7dae0c96d2b2e4bae Mon Sep 17 00:00:00 2001 From: Simo Sorce Date: Tue, 23 Sep 2008 14:30:06 -0400 Subject: Merge ldb_search() and ldb_search_exp_fmt() into a simgle function. The previous ldb_search() interface made it way too easy to leak results, and being able to use a printf-like expression turns to be really useful. --- source4/lib/ldb/examples/ldbreader.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'source4/lib/ldb/examples') diff --git a/source4/lib/ldb/examples/ldbreader.c b/source4/lib/ldb/examples/ldbreader.c index 6e58114531..e48b3d338a 100644 --- a/source4/lib/ldb/examples/ldbreader.c +++ b/source4/lib/ldb/examples/ldbreader.c @@ -88,8 +88,9 @@ int main(int argc, const char **argv) quite fine grained results with the LDAP search syntax, however it is a bit confusing to start with. See RFC2254. */ - if (LDB_SUCCESS != ldb_search(ldb, NULL, LDB_SCOPE_DEFAULT, - expression, NULL, &resultMsg) ) { + if (LDB_SUCCESS != ldb_search(ldb, ldb, &resultMsg, + NULL, LDB_SCOPE_DEFAULT, NULL, + "%s", expression)) { printf("Problem in search\n"); exit(-1); } -- cgit