Mageia Bugzilla – Attachment 11549 Details for
Bug 26284
Installer sometimes tries to reinstall firmware files that have been installed earlier - this is now a fatal error
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
New Account
|
Forgot Password
Proposed fix
fix-installer-marking-packages-as-installed.patch (text/plain), 1.67 KB, created by
Martin Whitaker
on 2020-03-14 18:32:11 CET
(
hide
)
Description:
Proposed fix
Filename:
MIME Type:
Creator:
Martin Whitaker
Created:
2020-03-14 18:32:11 CET
Size:
1.67 KB
patch
obsolete
>diff --git a/perl-install/install/pkgs.pm b/perl-install/install/pkgs.pm >index 91a57c2cf..2fcd0eccc 100644 >--- a/perl-install/install/pkgs.pm >+++ b/perl-install/install/pkgs.pm >@@ -868,24 +868,14 @@ sub _install_raw { > > my ($is_installing, $verify_just_closed); > my $exit_code = urpm::main_loop::run($packages, $packages->{state}, undef, undef, { >- open_helper => $callback, >- verify => sub { >- my ($_data, $_cb_type, $_pkg_id, $subtype, $_amout, $_total, $_pkg_name) = @_; >- if ($subtype eq 'start') { >- $is_installing = 0; >- } elsif ($subtype eq 'stop') { >- $is_installing = 1; >- $verify_just_closed = 1; >- } >- }, >+ open_helper => sub { >+ &$callback; >+ $is_installing = 0; >+ }, >+ verify => $callback, > close_helper => sub { > my ($db, $packages, $_type, $id) = @_; > &$callback; >- # ignore first close after end of verify: >- if ($is_installing && $verify_just_closed) { >- undef $verify_just_closed; >- return; >- } > return if !$is_installing; # don't check if it's installed if it's being verified > my $pkg = defined $id && $packages->{depslist}[$id] or return; > print $LOG $pkg->fullname . "\n"; >@@ -899,7 +889,11 @@ sub _install_raw { > } else { > log::l($pkg->name . " not installed, " . URPM::rpmErrorString()); > } >- }, inst => $callback, >+ }, >+ inst => sub { >+ &$callback; >+ $is_installing = 1; >+ }, > trans => $callback, > # FIXME: implement already_installed_or_not_installable > bad_signature => sub {
diff --git a/perl-install/install/pkgs.pm b/perl-install/install/pkgs.pm index 91a57c2cf..2fcd0eccc 100644 --- a/perl-install/install/pkgs.pm +++ b/perl-install/install/pkgs.pm @@ -868,24 +868,14 @@ sub _install_raw { my ($is_installing, $verify_just_closed); my $exit_code = urpm::main_loop::run($packages, $packages->{state}, undef, undef, { - open_helper => $callback, - verify => sub { - my ($_data, $_cb_type, $_pkg_id, $subtype, $_amout, $_total, $_pkg_name) = @_; - if ($subtype eq 'start') { - $is_installing = 0; - } elsif ($subtype eq 'stop') { - $is_installing = 1; - $verify_just_closed = 1; - } - }, + open_helper => sub { + &$callback; + $is_installing = 0; + }, + verify => $callback, close_helper => sub { my ($db, $packages, $_type, $id) = @_; &$callback; - # ignore first close after end of verify: - if ($is_installing && $verify_just_closed) { - undef $verify_just_closed; - return; - } return if !$is_installing; # don't check if it's installed if it's being verified my $pkg = defined $id && $packages->{depslist}[$id] or return; print $LOG $pkg->fullname . "\n"; @@ -899,7 +889,11 @@ sub _install_raw { } else { log::l($pkg->name . " not installed, " . URPM::rpmErrorString()); } - }, inst => $callback, + }, + inst => sub { + &$callback; + $is_installing = 1; + }, trans => $callback, # FIXME: implement already_installed_or_not_installable bad_signature => sub {
View Attachment As Raw
Actions:
View
Attachments on
bug 26284
:
11531
|
11532
| 11549