From 2d18445dc9ce9189da11f62ae9602e1f17ee64b6 Mon Sep 17 00:00:00 2001 From: Andreas Gohr Date: Tue, 3 Oct 2006 12:43:20 +0200 Subject: force rebind after opening new LDAP connection #751 This patch sets the private bound variable back to false if a new connection is opened. darcs-hash:20061003104320-7ad00-24370bcdc7beff5db7d7f2e68ea180763699ca5c.gz --- inc/auth/ldap.class.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'inc') diff --git a/inc/auth/ldap.class.php b/inc/auth/ldap.class.php index 523a2a397..4e2db6c05 100644 --- a/inc/auth/ldap.class.php +++ b/inc/auth/ldap.class.php @@ -265,7 +265,7 @@ class auth_ldap extends auth_basic { } /** - * Opens a connection to the configured LDAP server and sets the wnated + * Opens a connection to the configured LDAP server and sets the wanted * option on the connection * * @author Andreas Gohr @@ -273,6 +273,8 @@ class auth_ldap extends auth_basic { function _openLDAP(){ if($this->con) return true; // connection already established + $this->bound = false; + $port = ($this->cnf['port']) ? $this->cnf['port'] : 389; $this->con = @ldap_connect($this->cnf['server'],$port); if(!$this->con){ -- cgit v1.2.3