From 08712912e71330da7e19f7bb399390b65b2e601e Mon Sep 17 00:00:00 2001 From: =?utf8?q?Fr=C3=A9d=C3=A9ric=20Marchal?= Date: Tue, 25 Jan 2011 13:19:11 +0000 Subject: [PATCH] LDAP search error clarification If the LDAP search fails, in addition to the error message, the searched string and the base DN are reported. --- usertab.c | 1 + 1 file changed, 1 insertion(+) diff --git a/usertab.c b/usertab.c index f5afa75..08dfd4e 100644 --- a/usertab.c +++ b/usertab.c @@ -190,6 +190,7 @@ static void get_ldap_name(const char *userlogin,char *mappedname,int namelen) int rc= ldap_search_s(ldap_handle, LDAPBaseSearch, LDAP_SCOPE_SUBTREE, filtersearch, NULL, 0, &result); if ( rc != LDAP_SUCCESS ) { debuga(_("LDAP search failed: %s\n"), ldap_err2string(rc)); + debuga(_("looking for \"%s\" at or below \"%s\"\n"),filtersearch,LDAPBaseSearch); strncpy(mappedname,searchloginname,namelen-1); mappedname[namelen-1]='\0'; return; -- 2.47.2