diff options
author | Thierry Vignaud <tv@mageia.org> | 2012-08-24 11:16:57 +0000 |
---|---|---|
committer | Thierry Vignaud <tv@mageia.org> | 2012-08-24 11:16:57 +0000 |
commit | 24cac3777cc6d90dc68c890e86fb9303707ad470 (patch) | |
tree | a57c378966c0b4ef920c0803b64b036c02581a3e /urpm/main_loop.pm | |
parent | 683149d14d258d15bdb6ce5a4eda5475fdcbebb7 (diff) | |
download | urpmi-24cac3777cc6d90dc68c890e86fb9303707ad470.tar urpmi-24cac3777cc6d90dc68c890e86fb9303707ad470.tar.gz urpmi-24cac3777cc6d90dc68c890e86fb9303707ad470.tar.bz2 urpmi-24cac3777cc6d90dc68c890e86fb9303707ad470.tar.xz urpmi-24cac3777cc6d90dc68c890e86fb9303707ad470.zip |
(_verify_rpm) make sure to have a meaningfull return code when calling
'bad_signature' callback
(run) fix installing a package if user acks bogus signature
(regression introduced in commit r4862 on 2012-06-08:
"(_download_all) split it out of run()")
Diffstat (limited to 'urpm/main_loop.pm')
-rw-r--r-- | urpm/main_loop.pm | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/urpm/main_loop.pm b/urpm/main_loop.pm index 745494c9..09cf1024 100644 --- a/urpm/main_loop.pm +++ b/urpm/main_loop.pm @@ -126,7 +126,8 @@ sub _verify_rpm { : N("The following packages have bad signatures"); my $msg2 = N("Do you want to continue installation ?"); my $p = join "\n", @bad_signatures; - $callbacks->{bad_signature}->("$msg:\n$p\n", $msg2) or return 16; + my $res = $callbacks->{bad_signature}->("$msg:\n$p\n", $msg2); + return $res ? 0 : 16; } } @@ -361,7 +362,8 @@ sub run { #- verify packages if (!$force && ($options->{'verify-rpm'} || grep { $_->{'verify-rpm'} } @{$urpm->{media}})) { - _verify_rpm($urpm, $callbacks, \%transaction_sources_install, $transaction_sources); + my $res = _verify_rpm($urpm, $callbacks, \%transaction_sources_install, $transaction_sources); + $res and return $res; } #- install source package only (whatever the user is root or not, but use rpm for that). |