Do not call ldap_start_tls_s on ldapi:// connections.
[exim.git] / src / src / lookups / ldap.c
index 3db787ccee372ba01205afa89e0da628e8a5bc86..b8a326834f498a550d33596e1881fb73f6528ce8 100644 (file)
@@ -580,7 +580,7 @@ if (!lcp->bound ||
   {
   DEBUG(D_lookup) debug_printf("%sbinding with user=%s password=%s\n",
     (lcp->bound)? "re-" : "", user, password);
-  if (eldap_start_tls && !lcp->is_start_tls_called)
+  if (eldap_start_tls && !lcp->is_start_tls_called && !ldapi)
     {
 #if defined(LDAP_OPT_X_TLS) && !defined(LDAP_LIB_SOLARIS)
     /* The Oracle LDAP libraries (LDAP_LIB_TYPE=SOLARIS) don't support this.