Merge pull request #5227 from oGGy990/master

Fix ldap connection use after release in password plugin
pull/5241/head
Aleksander Machniak 9 years ago
commit 317372f046

@ -187,12 +187,14 @@ class rcube_ldap_password
); );
$result = $ldap->search($base, $filter, $options); $result = $ldap->search($base, $filter, $options);
$ldap->done();
if (is_a($result, 'PEAR_Error') || ($result->count() != 1)) { if (is_a($result, 'PEAR_Error') || ($result->count() != 1)) {
$ldap->done();
return ''; return '';
} }
$userDN = $result->current()->dn();
$ldap->done();
return $result->current()->dn(); return $userDN;
} }
/** /**

Loading…
Cancel
Save