diff options
author | Olivier Blin <oblin@mandriva.org> | 2004-07-16 11:00:45 +0000 |
---|---|---|
committer | Olivier Blin <oblin@mandriva.org> | 2004-07-16 11:00:45 +0000 |
commit | f53ad58e60ff5102010996379da1da1abfdf8cfe (patch) | |
tree | 7b951f688a70b4f0bb2fe9c699ea77f7944a5b26 | |
parent | 26069ec4f6b6d079a7ee289dc73310ef977f307f (diff) | |
download | drakx-f53ad58e60ff5102010996379da1da1abfdf8cfe.tar drakx-f53ad58e60ff5102010996379da1da1abfdf8cfe.tar.gz drakx-f53ad58e60ff5102010996379da1da1abfdf8cfe.tar.bz2 drakx-f53ad58e60ff5102010996379da1da1abfdf8cfe.tar.xz drakx-f53ad58e60ff5102010996379da1da1abfdf8cfe.zip |
fix predicted time when there is an error installing packages
-rw-r--r-- | perl-install/install_steps_gtk.pm | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/perl-install/install_steps_gtk.pm b/perl-install/install_steps_gtk.pm index a24b8d997..fad541525 100644 --- a/perl-install/install_steps_gtk.pm +++ b/perl-install/install_steps_gtk.pm @@ -612,6 +612,7 @@ If you don't have it, press Cancel to avoid installation from this Cd-Rom.", $na catch_cdie { $install_result = $o->install_steps::installPackages($packages) } sub { log::l("catch_cdie: $@"); + my $time = time(); if ($@ =~ /^error ordering package list: (.*)/) { $o->ask_yesorno('', [ N("There was an error ordering packages:"), $1, N("Go on anyway?") ], 1) and return 1; @@ -622,6 +623,8 @@ N("There was an error installing packages:"), $1, N("Go on anyway?") ], 1) and r ${$_[0]} = "already displayed"; } $w->destroy; + #- add the elapsed time (otherwise the predicted time will be rubbish) + $start_time += time() - $time; 0; }; if ($pkgs::cancel_install) { |