Allow IP range in the hosts file

Signed-off-by: Tom Eastep <teastep@shorewall.net>
This commit is contained in:
Tom Eastep 2012-10-07 15:55:00 -07:00
parent 431309678a
commit 0efc0451c1

View File

@ -763,7 +763,11 @@ sub add_group_to_zone($$$$$)
$new = \@exclusions;
}
$host = validate_net( $host, 1 ) unless $host =~ /^\+/;
if ( $host =~ /-/ ) {
&validate_range( split('-', $host, 2 ) )
} else {
$host = validate_net( $host, 1 ) unless $host =~ /^\+/;
}
unless ( $switched ) {
if ( $type == $zonetype ) {