From b757699e8b14fb0d5780e2513ffe64c087f5871d Mon Sep 17 00:00:00 2001 From: Volker Lendecke Date: Mon, 14 Aug 2006 12:54:37 +0000 Subject: r17536: Add a debug message citing the reason why an LDAP connection failed, inspired by Christian M Ambach . Volker (This used to be commit cf7c83d462dc766fa6f48728d0a4e8d534cc2bd4) --- source3/libads/ldap.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'source3/libads/ldap.c') diff --git a/source3/libads/ldap.c b/source3/libads/ldap.c index 5ff1ce435d..2ceafedd30 100644 --- a/source3/libads/ldap.c +++ b/source3/libads/ldap.c @@ -65,6 +65,11 @@ static void gotalarm_sig(void) ldp = ldap_open(server, port); + if (ldp == NULL) { + DEBUG(2,("Could not open LDAP connection to %s:%d: %s\n", + server, port, strerror(errno))); + } + /* Teardown timeout. */ CatchSignal(SIGALRM, SIGNAL_CAST SIG_IGN); alarm(0); -- cgit