From: cajus Date: Thu, 30 Oct 2008 20:23:06 +0000 (+0000) Subject: Enroll some for loops X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=a1645547e56da0cd41767ddce45d264b3336af85;p=gosa.git Enroll some for loops git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@12836 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/gosa-core/include/class_divlist.inc b/gosa-core/include/class_divlist.inc index 2cfbdb1f8..9a3f69991 100644 --- a/gosa-core/include/class_divlist.inc +++ b/gosa-core/include/class_divlist.inc @@ -298,7 +298,7 @@ class divlist { for($i = 0 ; $i < $nums ; $i ++ ){ $s_return.=""; $cnt=0; - for($a = 0 ; $a < (count($this->a_header[0])) ; $a ++ ) { + for($a = 0, $l= count($this->a_header[0]); $a < $l ; $a ++ ) { if($a ==(count($this->a_header[0])-1)){ $s_return.="\n "; } else { diff --git a/gosa-core/include/class_userinfo.inc b/gosa-core/include/class_userinfo.inc index e5123cf93..94337ae6f 100644 --- a/gosa-core/include/class_userinfo.inc +++ b/gosa-core/include/class_userinfo.inc @@ -596,7 +596,7 @@ class userinfo /* Skip objectClass '0' (e.g. users/0) get_permissions will ever return '' ?? */ if($oc == "0") continue; $tmp = $this->get_permissions($dn, $category."/".$oc); - for($i = 0 ; $i < strlen($types); $i++) { + for($i = 0, $l= strlen($types); $i < $l; $i++) { if(!preg_match("/".$types[$i]."/",$tmp)){ $acl = preg_replace("/".$types[$i]."/","",$acl); } diff --git a/gosa-core/include/functions.inc b/gosa-core/include/functions.inc index ca6b487f5..604c7b5a5 100644 --- a/gosa-core/include/functions.inc +++ b/gosa-core/include/functions.inc @@ -1088,7 +1088,7 @@ function getMenuCache() if(session::is_set('maxC')){ $b= session::get('maxC'); $q= ""; - for ($m=0;$m