mirror of
https://gitlab.com/shorewall/code.git
synced 2025-03-06 02:21:24 +01:00
Don't quote param values unnecessarily; add a comment to the emitted params
This commit is contained in:
parent
3bb67423c3
commit
0dc4cd7937
@ -98,12 +98,12 @@ our %EXPORT_TAGS = ( internal => [ qw( create_temp_script
|
|||||||
pop_open
|
pop_open
|
||||||
push_params
|
push_params
|
||||||
pop_params
|
pop_params
|
||||||
export_params
|
|
||||||
read_a_line
|
read_a_line
|
||||||
validate_level
|
validate_level
|
||||||
which
|
which
|
||||||
qt
|
qt
|
||||||
ensure_config_path
|
ensure_config_path
|
||||||
|
export_params
|
||||||
get_configuration
|
get_configuration
|
||||||
require_capability
|
require_capability
|
||||||
have_capability
|
have_capability
|
||||||
@ -3040,6 +3040,8 @@ sub export_params() {
|
|||||||
FW => 1,
|
FW => 1,
|
||||||
CONFDIR => 1 );
|
CONFDIR => 1 );
|
||||||
|
|
||||||
|
my $count = 0;
|
||||||
|
|
||||||
while ( my ( $param, $value ) = each %params ) {
|
while ( my ( $param, $value ) = each %params ) {
|
||||||
next if $exclude{$param};
|
next if $exclude{$param};
|
||||||
#
|
#
|
||||||
@ -3049,8 +3051,16 @@ sub export_params() {
|
|||||||
next if $value eq $ENV{$param};
|
next if $value eq $ENV{$param};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
emit "#\n# From the params file\n#" unless $count++;
|
||||||
|
|
||||||
|
if ( $value =~ /\s/ ) {
|
||||||
emit "$param='$value'";
|
emit "$param='$value'";
|
||||||
|
} else {
|
||||||
|
emit "$param=$value";
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
emit '' if $count;
|
||||||
}
|
}
|
||||||
|
|
||||||
#
|
#
|
||||||
|
Loading…
Reference in New Issue
Block a user