From 1f574040494630bf4bb5384fc049b3d830e9ea9b Mon Sep 17 00:00:00 2001 From: Andreas Gohr <andi@splitbrain.org> Date: Tue, 7 Mar 2006 20:19:15 +0100 Subject: [PATCH] fixed port assignment in ldap backend darcs-hash:20060307191915-7ad00-70d98478ebfd00fdbab4901bb254b96d20287348.gz --- inc/auth/ldap.class.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/inc/auth/ldap.class.php b/inc/auth/ldap.class.php index 852634e3d..f30606379 100644 --- a/inc/auth/ldap.class.php +++ b/inc/auth/ldap.class.php @@ -273,8 +273,8 @@ class auth_ldap extends auth_basic { function _openLDAP(){ if($this->con) return true; // connection already established - if(!$this->cnf['port']) $port = 636; - $this->con = @ldap_connect($this->cnf['server'],$this->cnf['port']); + $port = ($this->cnf['port']) ? $this->cnf['port'] : 636; + $this->con = @ldap_connect($this->cnf['server'],$port); if(!$this->con){ msg("LDAP: couldn't connect to LDAP server",-1); return false; -- GitLab