aboutsummaryrefslogtreecommitdiffstats
path: root/URPM.pm
diff options
context:
space:
mode:
authorFrancois Pons <fpons@mandriva.com>2002-12-17 13:57:31 +0000
committerFrancois Pons <fpons@mandriva.com>2002-12-17 13:57:31 +0000
commit6d2c5e8b142344fb51ab4d7adc8412deceaeab33 (patch)
tree8b7e14efbc797f29caace8a088ec3e31b109600e /URPM.pm
parent3b15f4893480acf473e276c571a1eda577621c72 (diff)
downloadperl-URPM-6d2c5e8b142344fb51ab4d7adc8412deceaeab33.tar
perl-URPM-6d2c5e8b142344fb51ab4d7adc8412deceaeab33.tar.gz
perl-URPM-6d2c5e8b142344fb51ab4d7adc8412deceaeab33.tar.bz2
perl-URPM-6d2c5e8b142344fb51ab4d7adc8412deceaeab33.tar.xz
perl-URPM-6d2c5e8b142344fb51ab4d7adc8412deceaeab33.zip
added very faster code, 3 times faster on traverse_tag with --env.
Diffstat (limited to 'URPM.pm')
-rw-r--r--URPM.pm4
1 files changed, 2 insertions, 2 deletions
diff --git a/URPM.pm b/URPM.pm
index 4e3b90f..c7c6c09 100644
--- a/URPM.pm
+++ b/URPM.pm
@@ -100,14 +100,14 @@ sub traverse_tag {
@names{@$names} = ();
if ($tag eq 'whatrequires') {
foreach (@{$urpm->{depslist} || []}) {
- if (grep { /^([^ \[]*)/ && exists $names{$1} } $_->requires) {
+ if (grep { exists $names{$_} } $_->requires_nosense) {
$callback and $callback->($_);
++$count;
}
}
} elsif ($tag eq 'whatconflicts') {
foreach (@{$urpm->{depslist} || []}) {
- if (grep { /^([^ \[]*)/ && exists $names{$1} } $_->conflicts) {
+ if (grep { exists $names{$_} } $_->conflicts_nosense) {
$callback and $callback->($_);
++$count;
}