]> git.sur5r.net Git - contagged/commitdiff
supress ldap_bind errors
authorAndreas Gohr <gohr@cosmocode.de>
Tue, 4 Sep 2007 14:41:36 +0000 (16:41 +0200)
committerAndreas Gohr <gohr@cosmocode.de>
Tue, 4 Sep 2007 14:41:36 +0000 (16:41 +0200)
darcs-hash:20070904144136-6e07b-e9cdde85ac2eff6e2afe544b868aaeb655af4b8b.gz

inc/functions.php

index 617888d7d86dadc1e18da2d9417d0b7dafc53d6f..f3b2ac05fac2660d67762f46e44793d5ea92059c 100644 (file)
@@ -67,7 +67,7 @@ function do_ldap_bind($user,$pass,$dn=""){
   if(empty($dn)){
     //anonymous bind to lookup users
     //blank binddn or blank bindpw will result in anonymous bind
-    if(!ldap_bind($LDAP_CON,$conf['anonbinddn'],$conf['anonbindpw'])){
+    if(!@ldap_bind($LDAP_CON,$conf['anonbinddn'],$conf['anonbindpw'])){
       die("can not bind for user lookup");
     }
 
@@ -89,7 +89,7 @@ function do_ldap_bind($user,$pass,$dn=""){
   }
 
   //bind with dn
-  if(ldap_bind($LDAP_CON,$dn,$pass)){
+  if(@ldap_bind($LDAP_CON,$dn,$pass)){
     //bind successful -> set up session
     set_session($user,$pass,$dn);
     return true;