From a8f3e3faa9c975d24c1c1605373d4d961b9b5f6a Mon Sep 17 00:00:00 2001 From: teastep Date: Mon, 16 Apr 2007 20:10:53 +0000 Subject: [PATCH] Fix hosts entries with wildcard interface git-svn-id: https://shorewall.svn.sourceforge.net/svnroot/shorewall/trunk@5951 fbd18981-670d-0410-9b5c-8dc0c1a9a2bb --- Shorewall-perl/Shorewall/Hosts.pm | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/Shorewall-perl/Shorewall/Hosts.pm b/Shorewall-perl/Shorewall/Hosts.pm index 0955ea20b..583bcb354 100644 --- a/Shorewall-perl/Shorewall/Hosts.pm +++ b/Shorewall-perl/Shorewall/Hosts.pm @@ -72,7 +72,7 @@ sub validate_hosts_file() my $interface; - if ( $hosts =~ /^([\w.@%-]+):(.*)$/ ) { + if ( $hosts =~ /^([\w.@%-]+\+?):(.*)$/ ) { $interface = $1; $hosts = $2; $zoneref->{options}{complex} = 1 if $hosts =~ /^\+/; @@ -103,9 +103,7 @@ sub validate_hosts_file() $optionsref = \%options; } - my @h = split ',', $hosts; - - add_group_to_zone( $zone, $type , $interface, \@h , $optionsref); + add_group_to_zone( $zone, $type , $interface, [ split ',', $hosts ] , $optionsref); progress_message " Host \"$line\" validated"; }