diff options
author | Thierry Vignaud <tv@mandriva.org> | 2009-01-06 16:55:46 +0000 |
---|---|---|
committer | Thierry Vignaud <tv@mandriva.org> | 2009-01-06 16:55:46 +0000 |
commit | 65b3487282e04759e8339875963b4403b690cc2c (patch) | |
tree | db2a9909981d6fd9b8cf7c65443bf12d56751675 | |
parent | 2f5d8a0bf898aac3c323f107428226a9ef12a3e3 (diff) | |
download | rpmdrake-65b3487282e04759e8339875963b4403b690cc2c.tar rpmdrake-65b3487282e04759e8339875963b4403b690cc2c.tar.gz rpmdrake-65b3487282e04759e8339875963b4403b690cc2c.tar.bz2 rpmdrake-65b3487282e04759e8339875963b4403b690cc2c.tar.xz rpmdrake-65b3487282e04759e8339875963b4403b690cc2c.zip |
warn traverse() is costly
-rw-r--r-- | Rpmdrake/pkg.pm | 1 | ||||
-rw-r--r-- | Rpmdrake/rpmnew.pm | 1 |
2 files changed, 2 insertions, 0 deletions
diff --git a/Rpmdrake/pkg.pm b/Rpmdrake/pkg.pm index be2ed7fb..de890e26 100644 --- a/Rpmdrake/pkg.pm +++ b/Rpmdrake/pkg.pm @@ -325,6 +325,7 @@ sub get_installed_packages { $base{$_} = \$n; } } + # costly: $db->traverse(sub { my ($pkg) = @_; update_pbar($gurpm); diff --git a/Rpmdrake/rpmnew.pm b/Rpmdrake/rpmnew.pm index 2e0d1971..2545e5cd 100644 --- a/Rpmdrake/rpmnew.pm +++ b/Rpmdrake/rpmnew.pm @@ -189,6 +189,7 @@ sub do_merge_if_needed() { my %pkg2rpmnew; my $wait = wait_msg(N("Please wait, searching...")); print "Searching .rpmnew and .rpmsave files...\n"; + # costly: open_rpm_db()->traverse(sub { my $n = my_fullname($_[0]); $pkg2rpmnew{$n} = [ grep { m|^/etc| && (-r "$_.rpmnew" || -r "$_.rpmsave") } map { chomp_($_) } $_[0]->files ]; |