Mailinglist Archive: zypp-commit (223 mails)

< Previous Next >
[zypp-commit] r10548 - /branches/SuSE-Linux-11_0-Branch/sat-solver/src/policy.c
  • From: mlschroe@xxxxxxxxxxxxxxxx
  • Date: Fri, 11 Jul 2008 20:08:54 -0000
  • Message-id: <20080711200854.B04652F121@xxxxxxxxxxxxxxxx>
Author: mlschroe
Date: Fri Jul 11 22:08:54 2008
New Revision: 10548

URL: http://svn.opensuse.org/viewcvs/zypp?rev=10548&view=rev
Log:
- disallow arch/vendor changes even if the package name changes

Modified:
branches/SuSE-Linux-11_0-Branch/sat-solver/src/policy.c

Modified: branches/SuSE-Linux-11_0-Branch/sat-solver/src/policy.c
URL:
http://svn.opensuse.org/viewcvs/zypp/branches/SuSE-Linux-11_0-Branch/sat-solver/src/policy.c?rev=10548&r1=10547&r2=10548&view=diff
==============================================================================
--- branches/SuSE-Linux-11_0-Branch/sat-solver/src/policy.c (original)
+++ branches/SuSE-Linux-11_0-Branch/sat-solver/src/policy.c Fri Jul 11 22:08:54
2008
@@ -404,7 +404,6 @@
Id p, *pp, n, p2, *pp2;
Id obs, *obsp;
Solvable *ps;
- Id vendormask;

queue_empty(qs);

@@ -418,7 +417,6 @@
* n = solvable Id
*/
n = s - pool->solvables;
- vendormask = pool_vendor2mask(pool, s->vendor);

/*
* look for updates for s
@@ -435,10 +433,6 @@
{
if (!solv->allowdowngrade && evrcmp(pool, s->evr, ps->evr,
EVRCMP_MATCH_RELEASE) > 0)
continue;
- if (!solv->allowarchchange && s->arch != ps->arch &&
policy_illegal_archchange(solv, s, ps))
- continue;
- if (!solv->allowvendorchange && s->vendor != ps->vendor &&
policy_illegal_vendorchange(solv, s, ps))
- continue;
}
}
else if (!solv->noupdateprovide && ps->obsoletes) /*
provides/obsoletes combination ? */
@@ -464,12 +458,29 @@
}
else
continue;
+ if (!allow_all)
+ {
+ if (!solv->allowarchchange && s->arch != ps->arch &&
policy_illegal_archchange(solv, s, ps))
+ continue;
+ if (!solv->allowvendorchange && s->vendor != ps->vendor &&
policy_illegal_vendorchange(solv, s, ps))
+ continue;
+ }
queue_push(qs, p);
}
if (solv->noupdateprovide && solv->obsoletes && solv->obsoletes[n -
solv->installed->start])
{
for (pp = solv->obsoletes_data + solv->obsoletes[n -
solv->installed->start]; (p = *pp++) != 0;)
- queue_push(qs, p);
+ {
+ ps = pool->solvables + p;
+ if (!allow_all)
+ {
+ if (!solv->allowarchchange && s->arch != ps->arch &&
policy_illegal_archchange(solv, s, ps))
+ continue;
+ if (!solv->allowvendorchange && s->vendor != ps->vendor &&
policy_illegal_vendorchange(solv, s, ps))
+ continue;
+ }
+ queue_push(qs, p);
+ }
}
}


--
To unsubscribe, e-mail: zypp-commit+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: zypp-commit+help@xxxxxxxxxxxx

< Previous Next >
This Thread
  • No further messages