]> git.ipfire.org Git - people/teissler/ipfire-2.x.git/commitdiff
Forward Firewall: when editing a group the rules where not read correctly, because...
authorAlexander Marx <amarx@ipfire.org>
Fri, 8 Feb 2013 09:33:04 +0000 (10:33 +0100)
committerMichael Tremer <michael.tremer@ipfire.org>
Fri, 9 Aug 2013 12:08:18 +0000 (14:08 +0200)
html/cgi-bin/fwhosts.cgi

index fb39ed86c2249af52b4afcbc5f2737906aaf444d..bb1b3492074aded4749cd255f9058f9168f73ee3 100755 (executable)
@@ -750,7 +750,7 @@ if ($fwhostsettings{'ACTION'} eq 'saveservicegrp')
                {
                        if($customservicegrp{$key}[0] eq $fwhostsettings{'SRVGRP_NAME'})
                        {
-                               $count=$customservicegrp{$key}[5];
+                               $count=$customservicegrp{$key}[3];
                                last;
                        }
                }
@@ -1611,7 +1611,6 @@ sub checkservicegroup
        {
                $errormessage.=$Lang::tr{'fwhost err groupempty'}."<br>";
        }
-       
        #check if name already exists
        if ($fwhostsettings{'updatesrvgrp'} ne 'on'){
                foreach my $key (keys %customservicegrp) {
@@ -1623,14 +1622,10 @@ sub checkservicegroup
        }
        #check if service already exists in group
        foreach my $key (keys %customservicegrp) {
-                       if($customservicegrp{$key}[0] eq $fwhostsettings{'SRVGRP_NAME'} && $customservicegrp{$key}[2] eq $fwhostsettings{'CUST_SRV'} ){
-                               $errormessage.=$Lang::tr{'fwhost err srvexist'}."<br>";
-                       
-                       }
+               if($customservicegrp{$key}[0] eq $fwhostsettings{'SRVGRP_NAME'} && $customservicegrp{$key}[2] eq $fwhostsettings{'CUST_SRV'} ){
+                       $errormessage.=$Lang::tr{'fwhost err srvexist'}."<br>";
                }
-       
-       
-       
+       }
        return $errormessage;
 }
 sub error