summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorStig Thormodsrud <stig@vyatta.com>2010-03-17 16:41:40 -0700
committerStig Thormodsrud <stig@vyatta.com>2010-03-17 16:41:40 -0700
commit61d52815b96d02f73adae13a1ce6aa76964ec1b1 (patch)
tree7fe9883913b8986a60e45d823cf43869f475cba8 /lib
parentbcc5bbbc3f216d1b83ac91c320300ad287e3e54d (diff)
downloadvyatta-cfg-firewall-61d52815b96d02f73adae13a1ce6aa76964ec1b1.tar.gz
vyatta-cfg-firewall-61d52815b96d02f73adae13a1ce6aa76964ec1b1.zip
Fix 5453: can't delete "address" under "firewall group <> address-group <> "
Diffstat (limited to 'lib')
-rwxr-xr-xlib/Vyatta/IpTables/IpSet.pm3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/Vyatta/IpTables/IpSet.pm b/lib/Vyatta/IpTables/IpSet.pm
index 5f68950..f53202c 100755
--- a/lib/Vyatta/IpTables/IpSet.pm
+++ b/lib/Vyatta/IpTables/IpSet.pm
@@ -352,10 +352,11 @@ sub delete_member_range {
}
} elsif ($self->{_type} eq 'address') {
my $start_ip = new NetAddr::IP("$start/$addr_range_mask");
- my $stop_ip = new NetAddr::IP($stop);
+ my $stop_ip = new NetAddr::IP("$stop/$addr_range_mask");
for (; $start_ip <= $stop_ip; $start_ip++) {
my $rc = $self->delete_member($start_ip->addr());
return $rc if defined $rc;
+ last if $start_ip->cidr() eq $start_ip->broadcast();
}
}
return;