Error out if given an unknown per-host option
This commit is contained in:
parent
564b315bfa
commit
967bf2f6e8
1 changed files with 2 additions and 5 deletions
|
@ -1976,11 +1976,8 @@ sub init_config {
|
||||||
|
|
||||||
my $svars = $protocols{$proto}{'variables'};
|
my $svars = $protocols{$proto}{'variables'};
|
||||||
my $conf = {'host' => $h, 'protocol' => $proto};
|
my $conf = {'host' => $h, 'protocol' => $proto};
|
||||||
|
for my $k (keys(%{$config{$h}})) {
|
||||||
# TODO: This silently ignores unknown options passed via --options.
|
my $def = $svars->{$k} or fatal("host $h: unknown option: $k");
|
||||||
for my $k (keys %$svars) {
|
|
||||||
next if !defined($config{$h}{$k});
|
|
||||||
my $def = $svars->{$k};
|
|
||||||
# _read_config already checked any value from the config file, so the purpose of this
|
# _read_config already checked any value from the config file, so the purpose of this
|
||||||
# check is to validate command-line options from --options which were merged into
|
# check is to validate command-line options from --options which were merged into
|
||||||
# $config{$h} above.
|
# $config{$h} above.
|
||||||
|
|
Loading…
Reference in a new issue