index 1da4e832c9b95fead61c302f443836260335dc7a..4dbe7995f770a073208bbc993fdc976cc4bfc2cf 100644 (file)
@@ -777,7 +777,9 @@ function get_sub_list($filter, $category,$sub_deps, $base= "", $attributes= arra
/* Remove , ("ou=1,ou=2.." => "ou=1") */
$sub_bases = array();
foreach($sub_deps as $key => $sub_base){
- $sub_bases[$key] = preg_replace("/,.*$/","",$sub_base);
+ if(!empty($sub_base)){
+ $sub_bases[$key] = preg_replace("/,.*$/","",$sub_base);
+ }
}
/* Check if we have enabled the sub_dir search support AND
@@ -790,9 +792,9 @@ function get_sub_list($filter, $category,$sub_deps, $base= "", $attributes= arra
/* Log this fall back, it may be an unpredicted behaviour.
*/
if(!count($sub_bases)){
- gosa_log("debug","get_sub_list","",$attributes,sprintf("get_sub_list(): Falling back to get_list(), due to empty sub_bases parameter. This may slow down GOsa.",$src,$attrs['dn']));
+ gosa_log("debug","get_sub_list","",$attributes,"get_sub_list(): Falling back to get_list(), due to empty sub_bases parameter. This may slow down GOsa.");
}
- $tmp = get_list($filter, $category,$base,$attributes,$flags | GL_SUBSEARCH);
+ $tmp = get_list($filter, $category,$base,$attributes,$flags);
return($tmp);
}