[dovecot-cvs] dovecot/src/auth db-ldap.c,1.41.2.14,1.41.2.15

tss at dovecot.org tss at dovecot.org
Tue Jan 9 11:40:08 UTC 2007


Update of /var/lib/cvs/dovecot/src/auth
In directory talvi:/tmp/cvs-serv3794

Modified Files:
      Tag: branch_1_0
	db-ldap.c 
Log Message:
If ldap_bind() fails directly, log the "ldap server down" errors more nicely.



Index: db-ldap.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/auth/db-ldap.c,v
retrieving revision 1.41.2.14
retrieving revision 1.41.2.15
diff -u -d -r1.41.2.14 -r1.41.2.15
--- db-ldap.c	12 Nov 2006 23:10:01 -0000	1.41.2.14
+++ db-ldap.c	9 Jan 2007 11:40:06 -0000	1.41.2.15
@@ -408,11 +408,10 @@
 	ldap_request->callback = db_ldap_bind_callback;
 	ldap_request->context = conn;
 
-	msgid = ldap_bind(conn->ld, conn->set.dn, conn->set.
-			  dnpass, LDAP_AUTH_SIMPLE);
+	msgid = ldap_bind(conn->ld, conn->set.dn, conn->set.dnpass,
+			  LDAP_AUTH_SIMPLE);
 	if (msgid == -1) {
-		i_error("ldap_bind(%s) failed: %s",
-			conn->set.dn, ldap_get_error(conn));
+		db_ldap_connect_finish(conn, ldap_get_error(conn));
 		i_free(ldap_request);
 		return -1;
 	}



More information about the dovecot-cvs mailing list