From: hickert Date: Tue, 21 Mar 2006 06:23:59 +0000 (+0000) Subject: Removed pass by reference X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=8247e8e4b01133119fcedfe2efb4b26fd4b73cd0;p=gosa.git Removed pass by reference git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@2864 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/plugins/admin/systems/class_termDNS.inc b/plugins/admin/systems/class_termDNS.inc index 12f9c211e..d7d43acf7 100644 --- a/plugins/admin/systems/class_termDNS.inc +++ b/plugins/admin/systems/class_termDNS.inc @@ -224,10 +224,11 @@ class termDNS extends plugin $smarty->assign("Zones",$this->Zones); $smarty->assign("ZoneKeys",($this->Zones)); $smarty->assign("IPisMust",(($this->IPisMust)||($this->DNS_is_account))); - $changeStateForRecords =""; - $smarty->assign("records",$this->generateRecordsList(&$changeStateForRecords)); + + $tmp = $this->generateRecordsList(); + $changeStateForRecords = $tmp['changeStateForRecords']; + $smarty->assign("records",$tmp['str']); $smarty->assign("changeStateForRecords",$changeStateForRecords); -// $smarty->assign("dNSClasses",array("IN"=>"IN")); $smarty->assign("staticAddress","*"); $display.= $smarty->fetch(get_template_path('network.tpl', TRUE)); return($display); @@ -407,7 +408,10 @@ $ldap->modify ($this->attrs); /* Generate a list of new ldap entries, & $delete contains all dns which should be deleted */ - $entries = $this->generate_LDAP_entries(&$delete); + $tmp = $this->generate_LDAP_entries(); + + $entries = $tmp['entries']; + $delete = $tmp['delete']; /* Delete dns */ foreach($delete as $dn => $del){ @@ -439,7 +443,7 @@ $ldap->modify ($this->attrs); /* Create html table with all used record types */ - function generateRecordsList($changeStateForRecords) + function generateRecordsList() { $changeStateForRecords = ""; @@ -469,7 +473,8 @@ $ldap->modify ($this->attrs); " ". " ". ""; - return($str); + $ret = array("str" => $str, "changeStateForRecords" => $changeStateForRecords); + return($ret); } /* Create a html select box which allows us to select different types of records */ @@ -518,7 +523,7 @@ $ldap->modify ($this->attrs); /* this is used to generate ldap friendly output of our dns configuration */ - function generate_LDAP_entries($delete) + function generate_LDAP_entries() { $entries = array(); $delete = array(); @@ -656,7 +661,8 @@ $ldap->modify ($this->attrs); } } - return($entries); + $ret = array("entries"=> $entries,"delete"=>$delete); + return($ret); } }