* by ano: use more uniq name in the ldap module; the old one clashed in solaris.
authorWilfried Göesgens <willi@citadel.org>
Wed, 7 Oct 2009 21:14:30 +0000 (21:14 +0000)
committerWilfried Göesgens <willi@citadel.org>
Wed, 7 Oct 2009 21:14:30 +0000 (21:14 +0000)
citadel/ldap.c

index 1bc38224c2a15a66b30fade8378a7ae40f94f160..0a4cb2c44a49fee407c10fb2794882b3c48e1c86 100644 (file)
@@ -9,7 +9,7 @@
  */
 
 
-int ldap_version = 3;
+int ctdl_require_ldap_version = 3;
 
 
 #include "sysdep.h"
@@ -89,7 +89,7 @@ int CtdlTryUserLDAP(char *username,
                return(errno);
        }
 
-       ldap_set_option(ldserver, LDAP_OPT_PROTOCOL_VERSION, &ldap_version);
+       ldap_set_option(ldserver, LDAP_OPT_PROTOCOL_VERSION, &ctdl_require_ldap_version);
 
        striplt(config.c_ldap_bind_dn);
        striplt(config.c_ldap_bind_pw);
@@ -217,7 +217,7 @@ int CtdlTryPasswordLDAP(char *user_dn, char *password)
 
        ldserver = ldap_init(config.c_ldap_host, config.c_ldap_port);
        if (ldserver) {
-               ldap_set_option(ldserver, LDAP_OPT_PROTOCOL_VERSION, &ldap_version);
+               ldap_set_option(ldserver, LDAP_OPT_PROTOCOL_VERSION, &ctdl_require_ldap_version);
                i = ldap_simple_bind_s(ldserver, user_dn, password);
                if (i == LDAP_SUCCESS) {
                        CtdlLogPrintf(CTDL_DEBUG, "LDAP: bind succeeded\n");