mirror of
https://gitlab.com/shorewall/code.git
synced 2025-06-21 10:18:58 +02:00
Concatenate match options when not KLUDGEFREE
Signed-off-by: Tom Eastep <teastep@shorewall.net>
This commit is contained in:
parent
01d07f55a9
commit
398c843643
@ -724,17 +724,19 @@ sub set_rule_option( $$$ ) {
|
|||||||
assert( defined( my $value1 = $ruleref->{$option} ) );
|
assert( defined( my $value1 = $ruleref->{$option} ) );
|
||||||
|
|
||||||
if ( $opttype == MATCH ) {
|
if ( $opttype == MATCH ) {
|
||||||
assert( $globals{KLUDGEFREE} );
|
if ( $globals{KLUDGEFREE} ) {
|
||||||
|
unless ( reftype $value1 ) {
|
||||||
|
unless ( reftype $value ) {
|
||||||
|
return if $value1 eq $value;
|
||||||
|
}
|
||||||
|
|
||||||
unless ( reftype $value1 ) {
|
$ruleref->{$option} = [ $ruleref->{$option} ];
|
||||||
unless ( reftype $value ) {
|
|
||||||
return if $value1 eq $value;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
$ruleref->{$option} = [ $ruleref->{$option} ];
|
push @{$ruleref->{$option}}, ( reftype $value ? @$value : $value );
|
||||||
|
} else {
|
||||||
|
$ruleref->{$option} = join(' ', $value1, $value );
|
||||||
}
|
}
|
||||||
|
|
||||||
push @{$ruleref->{$option}}, ( reftype $value ? @$value : $value );
|
|
||||||
} elsif ( $opttype == EXCLUSIVE ) {
|
} elsif ( $opttype == EXCLUSIVE ) {
|
||||||
$ruleref->{$option} .= ",$value";
|
$ruleref->{$option} .= ",$value";
|
||||||
} elsif ( $opttype == UNIQUE ) {
|
} elsif ( $opttype == UNIQUE ) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user