Fix missing action in macro or action

git-svn-id: https://shorewall.svn.sourceforge.net/svnroot/shorewall/trunk@6434 fbd18981-670d-0410-9b5c-8dc0c1a9a2bb
This commit is contained in:
teastep 2007-05-21 23:09:40 +00:00
parent 95418990fe
commit 28528770d4
2 changed files with 6 additions and 1 deletions

View File

@ -323,6 +323,8 @@ sub process_action1 ( $$ ) {
fatal_error "Parameter value not allowed in action files ($param)" if $paramtype & NATRULE;
}
fatal_error "Invalid or missing ACTION ( $wholetarget )" unless defined $target;
if ( find_macro $target ) {
process_macro1( $action, $macros{$target} );
} else {

View File

@ -808,7 +808,10 @@ sub process_macro ( $$$$$$$$$$$$ ) {
$mtarget = substitute_param $param, $mtarget;
}
my $action = isolate_basic_target $mtarget;
my $action = isolate_basic_target $mtarget;
fatal_error "Invalid or missing ACTION ( $mtarget )" unless defined $action;
my $actiontype = $targets{$action} || find_macro( $action );
fatal_error "Invalid Action ($mtarget) in macro" unless $actiontype & ( ACTION + STANDARD + NATRULE + MACRO );