mirror of
https://gitlab.com/shorewall/code.git
synced 2024-11-23 16:13:18 +01:00
More cleanup of validate_interface_file()
git-svn-id: https://shorewall.svn.sourceforge.net/svnroot/shorewall/trunk@8135 fbd18981-670d-0410-9b5c-8dc0c1a9a2bb
This commit is contained in:
parent
2d6e206a5f
commit
d0fd40ae0b
@ -607,9 +607,9 @@ sub validate_interfaces_file( $ )
|
||||
|
||||
( $interface, my ($port, $extra) ) = split /:/ , $interface, 3;
|
||||
|
||||
fatal_error "Invalid INTERFACE" if defined $extra || ! $interface;
|
||||
fatal_error "Invalid INTERFACE (" . join (':', $interface, $port, $extra ) . ')' if defined $extra || ! $interface;
|
||||
|
||||
fatal_error "Invalid Interface Name ($interface)" if $interface eq '+';
|
||||
fatal_error "Invalid Interface Name (+)" if $interface eq '+';
|
||||
|
||||
if ( defined $port ) {
|
||||
fatal_error qq("Virtual" interfaces are not supported -- see http://www.shorewall.net/Shorewall_and_Aliased_Interfaces.html) if $port =~ /^\d+$/;
|
||||
@ -741,7 +741,7 @@ sub validate_interfaces_file( $ )
|
||||
|
||||
my @networks = allipv4;
|
||||
|
||||
add_group_to_zone( $zone, $zoneref->{type}, $interface, \@networks, $optionsref ) if $zone && @networks;
|
||||
add_group_to_zone( $zone, $zoneref->{type}, $interface, \@networks, $optionsref ) if $zone;
|
||||
|
||||
$interfaces{$interface}{zone} = $zone; #Must follow the call to add_group_to_zone()
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user