aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGuillaume Cottenceau <gc@mandriva.com>2002-09-02 11:14:10 +0000
committerGuillaume Cottenceau <gc@mandriva.com>2002-09-02 11:14:10 +0000
commit0431eed48004e1b0a67a0d0e400e36d5c0487d8b (patch)
treee196a8f2563b50edb7f90db0afcca6260694001a
parentee2ffc381d99912c5829716337576da0d2de23f1 (diff)
downloadrpmdrake-0431eed48004e1b0a67a0d0e400e36d5c0487d8b.tar
rpmdrake-0431eed48004e1b0a67a0d0e400e36d5c0487d8b.tar.gz
rpmdrake-0431eed48004e1b0a67a0d0e400e36d5c0487d8b.tar.bz2
rpmdrake-0431eed48004e1b0a67a0d0e400e36d5c0487d8b.tar.xz
rpmdrake-0431eed48004e1b0a67a0d0e400e36d5c0487d8b.zip
to know if there are deps, don't compare sizes of nodes and
nodes_with_deps since there can be some cantbeselected; so first calculate the difference and see if it's void
-rwxr-xr-xrpmdrake5
1 files changed, 3 insertions, 2 deletions
diff --git a/rpmdrake b/rpmdrake
index 353ac3ec..6793fd00 100755
--- a/rpmdrake
+++ b/rpmdrake
@@ -313,8 +313,9 @@ or you already installed all of them."));
my @nodes_with_deps;
my $deps_msg = sub {
my ($title, $msg, $nodes, $nodes_with_deps) = @_;
- @$nodes_with_deps > @$nodes or return 1;
- interactive_msg($title, $msg . $formatlistpkg->(sort { $a cmp $b } difference2($nodes_with_deps, $nodes)),
+ my @deps = difference2($nodes_with_deps, $nodes);
+ @deps > 0 or return 1;
+ interactive_msg($title, $msg . $formatlistpkg->(sort { $a cmp $b } @deps),
yesno => 1, text => { yes => _("Ok"), no => _("Cancel") });
};
if ($MODE eq 'remove') {