mirror of
https://gitlab.com/shorewall/code.git
synced 2024-12-22 22:30:58 +01:00
Correct tcrules update
Signed-off-by: Tom Eastep <teastep@shorewall.net>
This commit is contained in:
parent
af2b7910bd
commit
f5c6a6fe82
@ -3252,11 +3252,15 @@ sub setup_tc( $ ) {
|
||||
|
||||
close $mangle, directive_callback( 0 ) if $tcrules;
|
||||
|
||||
} elsif ( $tcrules && -f ( my $fn = find_file( 'tcrules' ) ) ) {
|
||||
if ( unlink $fn ) {
|
||||
warning_message "Empty tcrules file ($fn) removed";
|
||||
} else {
|
||||
warning_message "Unable to remove empty tcrules file $fn: $!";
|
||||
} elsif ( $tcrules ) {
|
||||
close $mangle, directive_callback( 0 ) if $tcrules;
|
||||
|
||||
if ( -f ( my $fn = find_file( 'tcrules' ) ) ) {
|
||||
if ( unlink $fn ) {
|
||||
warning_message "Empty tcrules file ($fn) removed";
|
||||
} else {
|
||||
warning_message "Unable to remove empty tcrules file $fn: $!";
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user