summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--source3/libads/ldap.c5
1 files changed, 5 insertions, 0 deletions
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);