diff options
-rw-r--r-- | NEWS | 2 | ||||
-rw-r--r-- | rpmdrake.pm | 3 |
2 files changed, 5 insertions, 0 deletions
@@ -1,5 +1,7 @@ - rpmdrake: o do not crash if package is unknow (#39608) + o do not crash if config file set empty values for some variables + (eg: after old buggy gurpmi.addmedia garbaged it) (#39511) - gurpmi.addmedia: o handle --mirrorlist (Anssi) diff --git a/rpmdrake.pm b/rpmdrake.pm index 4e2a3482..da4a8570 100644 --- a/rpmdrake.pm +++ b/rpmdrake.pm @@ -169,6 +169,9 @@ sub readconf() { ${$config{$_}{var}} = $config{$_}{default} foreach keys %config; foreach my $l (cat_($configfile)) { $l =~ /^\Q$_\E (.*)/ and ${$config{$_}{var}} = [ split ' ', $1 ] foreach keys %config; + foreach (keys %config) { + $l =~ /^\Q$_\E (.*)/ and $1 and ${$config{$_}{var}} = [ split ' ', $1 ]; + } } # special cases: $::rpmdrake_options{'no-confirmation'} = $no_confirmation->[0] if !defined $::rpmdrake_options{'no-confirmation'}; |