Catch invalid use of COMMENT in action body

git-svn-id: https://shorewall.svn.sourceforge.net/svnroot/shorewall/trunk@6209 fbd18981-670d-0410-9b5c-8dc0c1a9a2bb
This commit is contained in:
teastep 2007-05-03 15:13:51 +00:00
parent 61fb84d23b
commit 92823f08f3

View File

@ -296,7 +296,9 @@ sub process_actions1() {
fatal_error "An action may not invoke itself" if $target eq $action;
add_requiredby $wholetarget, $action if $targettype & ACTION;
} elsif ( $target ne 'COMMENT' ) {
} elsif ( $target eq 'COMMENT' ) {
fatal_error "Invalid TARGET ($wholetarget)" unless $wholetarget eq $target;
} else {
$target =~ s!/.*$!!;
if ( find_macro $target ) {