aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAvatar Marc-Antoine Perennou <Marc-Antoine@Perennou.com> 2012-05-31 11:50:10 +0200
committerAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2012-06-02 14:05:04 +0100
commitd4661a13032a90c7be9a03b5c9ad11845f8cc2f6 (patch)
tree3594e5aab3c50937766312a26d384a24d164ec62
parent1cd262f1c2b1d410ab9f7a510cbe4dd4394317cb (diff)
downloadpaludis-d4661a13032a90c7be9a03b5c9ad11845f8cc2f6.tar.gz
paludis-d4661a13032a90c7be9a03b5c9ad11845f8cc2f6.tar.xz
Fix interest_in_spec_helper
We were blacklisting suggestions before checking if they were installed if they were masked into suggestions.conf, resulting in a maybe incomplete world set calculation Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>
-rw-r--r--paludis/resolver/interest_in_spec_helper.cc22
1 files changed, 11 insertions, 11 deletions
diff --git a/paludis/resolver/interest_in_spec_helper.cc b/paludis/resolver/interest_in_spec_helper.cc
index 4df3f74..e34cf50 100644
--- a/paludis/resolver/interest_in_spec_helper.cc
+++ b/paludis/resolver/interest_in_spec_helper.cc
@@ -312,6 +312,17 @@ InterestInSpecHelper::operator() (
if ((! spec_group.empty()) && _imp->ignore_groups.end() != _imp->ignore_groups.find(spec_group))
return si_ignore;
+ /* we also take suggestions and recommendations that have already been installed */
+ if (dep.spec().if_package())
+ {
+ const std::shared_ptr<const PackageIDSequence> installed_ids(
+ (*_imp->env)[selection::SomeArbitraryVersion(
+ generator::Matches(*dep.spec().if_package(), dep.from_id(), { }) |
+ filter::InstalledAtRoot(_imp->env->system_root_key()->parse_value()))]);
+ if (! installed_ids->empty())
+ return si_take;
+ }
+
if (dep.spec().if_package() && (suggestion || recommendation))
{
auto e(_imp->env->interest_in_suggestion(id, *dep.spec().if_package()));
@@ -337,17 +348,6 @@ InterestInSpecHelper::operator() (
return si_ignore;
}
- /* we also take suggestions and recommendations that have already been installed */
- if (dep.spec().if_package())
- {
- const std::shared_ptr<const PackageIDSequence> installed_ids(
- (*_imp->env)[selection::SomeArbitraryVersion(
- generator::Matches(*dep.spec().if_package(), dep.from_id(), { }) |
- filter::InstalledAtRoot(_imp->env->system_root_key()->parse_value()))]);
- if (! installed_ids->empty())
- return si_take;
- }
-
return si_untaken;
}
else