Code

Updated focus.js
[gosa.git] / gosa-core / include / class_config.inc
index bbe1c17948e94aad56f5d7975f9d5f96641765a1..e9f3bac77741508bbef1b06ca074cbd6644788dd 100644 (file)
@@ -106,7 +106,7 @@ class config  {
       $msg = sprintf(_("XML error in gosa.conf: %s at line %d"),
             xml_error_string(xml_get_error_code($this->parser)),
             xml_get_current_line_number($this->parser));
-      msg_dialog::display(_("Config file parsing"), $msg, FATAL_ERROR_DIALOG);
+      msg_dialog::display(_("Configuration error"), $msg, FATAL_ERROR_DIALOG);
       exit;
     }
   }
@@ -216,13 +216,8 @@ class config  {
 
   function get_ldap_link($sizelimit= FALSE)
   {
+    if($this->ldap === NULL || !is_resource($this->ldap->cid)){
 
-# REuse last ldap valid handle again.
-# DISABLED due to unpredictable results.
-
-#
-#    if($this->ldap === NULL || !is_resource($this->ldap->cid)){
-#
       /* Build new connection */
       $this->ldap= ldap_init ($this->current['SERVER'], $this->current['BASE'],
           $this->current['ADMIN'], $this->current['PASSWORD']);
@@ -251,8 +246,9 @@ class config  {
       } else {
         $this->ldap->referrals= $this->current['REFERRAL'];
       }
-#    }
-    return ($this->ldap);
+    }
+
+    return new ldapMultiplexer($this->ldap);
   }
 
   function set_current($name)