aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChristophe Fergeau <cfergeau@mandriva.com>2009-03-27 14:58:32 +0000
committerChristophe Fergeau <cfergeau@mandriva.com>2009-03-27 14:58:32 +0000
commit2c6c1adc02c7ae773ee96acd4b023c039b7df153 (patch)
treedc7ced4d08b0bbfe9a9dc8920f23bad607bb1d97
parent162a434adbfca7aae278435d51da88af90eff10a (diff)
downloadperl-URPM-2c6c1adc02c7ae773ee96acd4b023c039b7df153.tar
perl-URPM-2c6c1adc02c7ae773ee96acd4b023c039b7df153.tar.gz
perl-URPM-2c6c1adc02c7ae773ee96acd4b023c039b7df153.tar.bz2
perl-URPM-2c6c1adc02c7ae773ee96acd4b023c039b7df153.tar.xz
perl-URPM-2c6c1adc02c7ae773ee96acd4b023c039b7df153.zip
Fix regression introduced in fix for bug #47803
This reverts the previous commit only compute diff_provides when the package is newly rejected, in set_rejected_and_compute_diff_provides Try this incremental patch. It fixes set_rejected_and_compute_diff_provides to not compute diff_provides if package was already rejected (and thus the dependencies properly handled already).
-rw-r--r--NEWS3
-rw-r--r--URPM/Resolve.pm10
2 files changed, 8 insertions, 5 deletions
diff --git a/NEWS b/NEWS
index 5349c95..0c807b9 100644
--- a/NEWS
+++ b/NEWS
@@ -1,6 +1,3 @@
-- revert part of the fix for bug #47803 because it's breaking upgrades
- from 2008.1
-
Version 3.28 - 25 March 2009, by Christophe Fergeau
- postpone user choices as much as possible to avoid asking the user
diff --git a/URPM/Resolve.pm b/URPM/Resolve.pm
index ef956cc..d12aa91 100644
--- a/URPM/Resolve.pm
+++ b/URPM/Resolve.pm
@@ -769,7 +769,11 @@ sub set_rejected {
sub set_rejected_and_compute_diff_provides {
my ($urpm, $state, $diff_provides_h, $rdep) = @_;
- set_rejected($urpm, $state, $rdep);
+ my $newly_rejected = set_rejected($urpm, $state, $rdep);
+
+ #- no need to compute diff_provides if package was already rejected
+ $newly_rejected or return;
+
_compute_diff_provides_of_removed_pkg($urpm, $state, $diff_provides_h, $rdep->{rejected_pkg});
}
@@ -1235,11 +1239,13 @@ sub _handle_diff_provides {
} elsif ($options{keep}) {
backtrack_selected_psel_keep($urpm, $db, $state, $pkg, [ scalar $p->fullname ]);
} else {
- resolve_rejected_($urpm, $db, $state, $properties, {
+ my %diff_provides_h;
+ set_rejected_and_compute_diff_provides($urpm, $state, \%diff_provides_h, {
rejected_pkg => $p, removed => 1,
from => $pkg,
why => { unsatisfied => \@unsatisfied },
});
+ push @$diff_provides, map { +{ name => $_, pkg => $pkg } } keys %diff_provides_h;
}
}
}