On clone create a new instance of the Configuration

To avide effects on the original instance of Connection when the clone
is modified, for instance on authentication checks.
This commit is contained in:
Arthur Schiwon 2014-03-21 15:27:51 +01:00
parent 37af74efb3
commit 055a09e487
1 changed files with 2 additions and 0 deletions

View File

@ -78,6 +78,8 @@ class Connection extends LDAPUtility {
//a cloned instance inherits the connection resource. It may use it, //a cloned instance inherits the connection resource. It may use it,
//but it may not disconnect it //but it may not disconnect it
$this->dontDestruct = true; $this->dontDestruct = true;
$this->configuration = new Configuration($this->configPrefix,
!is_null($this->configID));
} }
public function __get($name) { public function __get($name) {