diff options
-rw-r--r-- | NEWS | 1 | ||||
-rwxr-xr-x | mgaapplet | 8 |
2 files changed, 9 insertions, 0 deletions
@@ -1,3 +1,4 @@ +- check that choosen download directory is owned by root (mga#6083) - drop support for Enterprise & PowerPack media (mga#6292) - drop support for extended maintenance @@ -395,6 +395,10 @@ sub confirm_upgrade() { Gtk2::FileChooserButton->new(N("Browse"), 'select-folder'), 'current-folder-changed' => sub { $temp_dir = $_[0]->get_current_folder; + my $ok = 1; + require urpm; + urpm::check_cache_dir({ fatal => sub { $ok = 0 } }, $temp_dir); + $ok or ask_warn(N("Error"), N("You must choose a directory owned by the super administrator!")); }); $browse->set_current_folder($download_dir); @@ -426,6 +430,10 @@ sub confirm_upgrade() { setVar('DO_NOT_ASK_FOR_DISTRO_UPGRADE', bool2text($warn_me)); $local_config{DO_NOT_ASK_FOR_DISTRO_UPGRADE} = bool2text($warn_me); if ($res) { + require urpm; + my $ok = 1; + urpm::check_cache_dir({ fatal => sub { $ok = 0 } }, $temp_dir); + $ok or goto &confirm_upgrade; $download_dir = $temp_dir; really_confirm_upgrade(); } else { |