From 37039ea5b0b460b0ac088e1e902a28d2b4135625 Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Mon, 26 Nov 2007 06:12:01 +0100 Subject: [PATCH] r26131: Ensure we show the right errors in the NULL base DN case. Based on MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit bug 5090 by Matthias Dieter Wallnöfer Andrew Bartlett (This used to be commit cc2d0c9f15a9c687d212df14d8ffb6c60ad15242) --- source4/lib/ldb/ldb_tdb/ldb_search.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/source4/lib/ldb/ldb_tdb/ldb_search.c b/source4/lib/ldb/ldb_tdb/ldb_search.c index bf6bd91fc29..da899c361ed 100644 --- a/source4/lib/ldb/ldb_tdb/ldb_search.c +++ b/source4/lib/ldb/ldb_tdb/ldb_search.c @@ -530,10 +530,12 @@ int ltdb_search(struct ldb_module *module, struct ldb_request *req) ldb_asprintf_errstring(module->ldb, "NULL Base DN invalid for a base search"); ret = LDB_ERR_INVALID_DN_SYNTAX; + break; case LDB_SCOPE_ONELEVEL: ldb_asprintf_errstring(module->ldb, "NULL Base DN invalid for a one-level search"); ret = LDB_ERR_INVALID_DN_SYNTAX; + break; case LDB_SCOPE_SUBTREE: default: /* We accept subtree searches from a NULL base DN, ie over the whole DB */