From 55e1bead6fffda2d64707436bbc5137078f732ef Mon Sep 17 00:00:00 2001 From: Douglas Bagnall Date: Thu, 28 Dec 2023 12:45:41 +1300 Subject: [PATCH] ldb-samba: matching rules: notify of search failure in transitive filter This is for debugging, not for master, though a version with DBG_INFO might be good there. BUG: https://bugzilla.samba.org/show_bug.cgi?id=15515 Signed-off-by: Douglas Bagnall --- lib/ldb-samba/ldb_matching_rules.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/lib/ldb-samba/ldb_matching_rules.c b/lib/ldb-samba/ldb_matching_rules.c index 59d1385f4e3..c48c7917a60 100644 --- a/lib/ldb-samba/ldb_matching_rules.c +++ b/lib/ldb-samba/ldb_matching_rules.c @@ -74,6 +74,12 @@ static int ldb_eval_transitive_filter_helper(TALLOC_CTX *mem_ctx, attrs, DSDB_MARK_REQ_UNTRUSTED); if (ret != LDB_SUCCESS) { + const char *dnstr = ldb_dn_get_linearized(to_visit->dn); + DBG_ERR("search failure (%d: %s) looking for '%s' on '%s'\n", + ret, + ldb_strerror(ret), + attr, + dnstr); talloc_free(tmp_ctx); return ret; } -- 2.34.1