forked from extern/shorewall_code
Ensure that the chain origin is used when there is no rule origin
Signed-off-by: Tom Eastep <teastep@shorewall.net>
This commit is contained in:
parent
916a392fb0
commit
bd9e8142b9
@ -1254,6 +1254,8 @@ sub set_irule_comment( $$ ) {
|
||||
|
||||
our $rule_comments;
|
||||
|
||||
$ruleref->{origin} ||= $chainref->{origin};
|
||||
|
||||
if ( $rule_comments ) {
|
||||
$ruleref->{comment} = $ruleref->{origin} || $comment;
|
||||
} else {
|
||||
@ -6350,7 +6352,7 @@ sub log_rule_limit( $$$$$$$$;$ ) {
|
||||
$ruleref = insert_rule1 ( $chainref , 0 , $matches . $prefix );
|
||||
}
|
||||
|
||||
$ruleref->{origin} = $origin ||= $chainref->{origin} if reftype $ruleref;
|
||||
$ruleref->{origin} = $origin if reftype( $ruleref ) && $origin;
|
||||
|
||||
$ruleref;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user