aboutsummaryrefslogtreecommitdiffstats
path: root/Rpmdrake
diff options
context:
space:
mode:
authorThierry Vignaud <tv@mandriva.org>2007-03-22 14:52:58 +0000
committerThierry Vignaud <tv@mandriva.org>2007-03-22 14:52:58 +0000
commit2fec2aafb9ddd58d1bfdd1e819e045d2f4634891 (patch)
tree6e6d3ca9fcb611ce9414c1f86badc08598a7caf0 /Rpmdrake
parentcea22e6dace99bad88ffdf988a24c514551d9e42 (diff)
downloadrpmdrake-2fec2aafb9ddd58d1bfdd1e819e045d2f4634891.tar
rpmdrake-2fec2aafb9ddd58d1bfdd1e819e045d2f4634891.tar.gz
rpmdrake-2fec2aafb9ddd58d1bfdd1e819e045d2f4634891.tar.bz2
rpmdrake-2fec2aafb9ddd58d1bfdd1e819e045d2f4634891.tar.xz
rpmdrake-2fec2aafb9ddd58d1bfdd1e819e045d2f4634891.zip
(callback_choices) do not return random package when user canceled the dialog
Diffstat (limited to 'Rpmdrake')
-rw-r--r--Rpmdrake/gui.pm2
1 files changed, 1 insertions, 1 deletions
diff --git a/Rpmdrake/gui.pm b/Rpmdrake/gui.pm
index a986d894..64b1e604 100644
--- a/Rpmdrake/gui.pm
+++ b/Rpmdrake/gui.pm
@@ -474,7 +474,7 @@ sub callback_choices {
my @choices = interactive_list_(N("Please choose"), (scalar(@$choices) == 1 ?
N("The following package is needed:") : N("One of the following packages is needed:")),
[ map { urpm_name($_) } @$choices ], $callback);
- $choices->[$choices[0]];
+ $choices[0] ? $choices->[$choices[0]] : undef;
}
sub toggle_nodes {