solver: fix cleaning of packages that got replaced by provides

cute-signatures
Timo Teräs 2014-04-10 09:52:40 +03:00
parent 50cec5b959
commit 9fa64ca1db
1 changed files with 4 additions and 1 deletions

View File

@ -786,10 +786,13 @@ static void cset_gen_name_remove(struct apk_solver_state *ss, struct apk_package
{ {
struct apk_name *name = pkg->name, **pname; struct apk_name *name = pkg->name, **pname;
if (name->ss.chosen.pkg != NULL || name->ss.in_changeset) if (pkg->ss.in_changeset ||
(name->ss.chosen.pkg != NULL &&
name->ss.chosen.pkg->name == name))
return; return;
name->ss.in_changeset = 1; name->ss.in_changeset = 1;
pkg->ss.in_changeset = 1;
foreach_array_item(pname, pkg->name->rinstall_if) foreach_array_item(pname, pkg->name->rinstall_if)
cset_check_removal_by_iif(ss, *pname); cset_check_removal_by_iif(ss, *pname);
record_change(ss, pkg, NULL); record_change(ss, pkg, NULL);