From e06ca342980d1dad204c2505b2dbcdb80cc58ebb Mon Sep 17 00:00:00 2001 From: Tom Eastep Date: Sun, 19 Sep 2010 08:03:01 -0700 Subject: [PATCH] Add redundancy warning re 'blacklst' --- Shorewall/Perl/Shorewall/Zones.pm | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/Shorewall/Perl/Shorewall/Zones.pm b/Shorewall/Perl/Shorewall/Zones.pm index 5859faf06..b4e834837 100644 --- a/Shorewall/Perl/Shorewall/Zones.pm +++ b/Shorewall/Perl/Shorewall/Zones.pm @@ -456,10 +456,12 @@ sub process_zone( \$ ) { if ( $zoneref->{options}{in_out}{blacklist} ) { for ( qw/in out/ ) { - warning_message( "Redundant 'blacklist' in " . uc( $_ ) . '_OPTIONS' ) if $zoneref->{options}{$_}{blacklist}; + if ( $zoneref->{options}{$_}{blacklist} ) { + warning_message( "Redundant 'blacklist' in " . uc( $_ ) . '_OPTIONS' ); + } else { + $zoneref->{options}{$_}{blacklist} = 1; + } } - - $zoneref->{options}{in}{blacklist} = $zoneref->{options}{out}{blacklist} = 1 ; } return $zone;