diff options
author | Thierry Vignaud <tv@mandriva.org> | 2008-05-08 07:48:05 +0000 |
---|---|---|
committer | Thierry Vignaud <tv@mandriva.org> | 2008-05-08 07:48:05 +0000 |
commit | 8f81239fc31a0e33790bb95b2c71b90c39ad888e (patch) | |
tree | c2c665c370547f59beea3e3bfe3e388d0dd1bdb9 /Rpmdrake | |
parent | a373e22f942f4ee687fa787cf69b5f01cd778a1e (diff) | |
download | rpmdrake-8f81239fc31a0e33790bb95b2c71b90c39ad888e.tar rpmdrake-8f81239fc31a0e33790bb95b2c71b90c39ad888e.tar.gz rpmdrake-8f81239fc31a0e33790bb95b2c71b90c39ad888e.tar.bz2 rpmdrake-8f81239fc31a0e33790bb95b2c71b90c39ad888e.tar.xz rpmdrake-8f81239fc31a0e33790bb95b2c71b90c39ad888e.zip |
warn only once about priority upgrades (#39737)
Diffstat (limited to 'Rpmdrake')
-rw-r--r-- | Rpmdrake/gui.pm | 3 | ||||
-rw-r--r-- | Rpmdrake/pkg.pm | 6 |
2 files changed, 8 insertions, 1 deletions
diff --git a/Rpmdrake/gui.pm b/Rpmdrake/gui.pm index ebd3f2df..0a2458d1 100644 --- a/Rpmdrake/gui.pm +++ b/Rpmdrake/gui.pm @@ -482,7 +482,8 @@ sub ask_browse_tree_given_widgets_for_rpmdrake { $urpm_obj->set_flag_skip(0); } - if ($Rpmdrake::pkg::need_restart) { + if ($Rpmdrake::pkg::need_restart && !$priority_up_alread_warned) { + $priority_up_alread_warned = 1; interactive_msg(N("Warning"), '<b>' . N("Rpmdrake or one of its priority dependencies needs to be updated first. Rpmdrake will then restart.") . '</b>' . "\n\n"); } diff --git a/Rpmdrake/pkg.pm b/Rpmdrake/pkg.pm index 74bde389..e3f2dc92 100644 --- a/Rpmdrake/pkg.pm +++ b/Rpmdrake/pkg.pm @@ -49,6 +49,7 @@ use urpm::args qw(); use Exporter; our @ISA = qw(Exporter); our @EXPORT = qw( + $priority_up_alread_warned download_callback extract_header find_installed_version @@ -62,6 +63,9 @@ use ugtk2 qw(:all); use Gtk2::Pango; use Gtk2::Gdk::Keysyms; +our $priority_up_alread_warned; + + sub run_rpm { foreach (qw(LANG LC_CTYPE LC_NUMERIC LC_TIME LC_COLLATE LC_MONETARY LC_MESSAGES LC_PAPER LC_NAME LC_ADDRESS LC_TELEPHONE LC_MEASUREMENT LC_IDENTIFICATION LC_ALL)) { local $ENV{$_} = $ENV{$_} . '.UTF-8' if $ENV{$_} && $ENV{$_} !~ /UTF-8/; @@ -359,6 +363,8 @@ sub get_pkgs { my $_drop_lock = before_leaving { undef $urpm->{lock} }; + $priority_up_alread_warned = 0; + # update media list in case warn_about_media() added some: @update_medias = get_update_medias($urpm); |