summaryrefslogtreecommitdiffstats
path: root/apps
diff options
context:
space:
mode:
authorArthur Schiwon <blizzz@owncloud.com>2012-10-26 13:30:07 +0200
committerArthur Schiwon <blizzz@owncloud.com>2012-10-26 21:54:34 +0200
commit3f78a8190ff5403d03b5539f59d22f63674aaee6 (patch)
tree78b506bcc867ef6514d6ea0496064615759731b1 /apps
parent46871e9b2e39750d64d16fb127cbfd608477287b (diff)
downloadnextcloud-server-3f78a8190ff5403d03b5539f59d22f63674aaee6.tar.gz
nextcloud-server-3f78a8190ff5403d03b5539f59d22f63674aaee6.zip
LDAP: check for resource before unbinding
Diffstat (limited to 'apps')
-rw-r--r--apps/user_ldap/lib/connection.php4
1 files changed, 3 insertions, 1 deletions
diff --git a/apps/user_ldap/lib/connection.php b/apps/user_ldap/lib/connection.php
index bf65d9ad91c..cc24ea62434 100644
--- a/apps/user_ldap/lib/connection.php
+++ b/apps/user_ldap/lib/connection.php
@@ -64,7 +64,9 @@ class Connection {
}
public function __destruct() {
- @ldap_unbind($this->ldapConnectionRes);
+ if(is_resource($this->ldapConnectionRes)) {
+ @ldap_unbind($this->ldapConnectionRes);
+ };
}
public function __get($name) {