diff options
author | Michael Schroeder <mls@suse.de> | 2014-07-08 14:09:48 +0200 |
---|---|---|
committer | Michael Schroeder <mls@suse.de> | 2014-07-08 14:09:48 +0200 |
commit | c50b68298dd430a3cdf58a0c252a890fcdc23dd2 (patch) | |
tree | 36a0eeef535d951830b5109f0c6afbc069e8ab70 /src | |
parent | c56bef07b2db954ae09d1d2817336ffb9eb537b1 (diff) | |
download | libsolv-c50b68298dd430a3cdf58a0c252a890fcdc23dd2.tar.gz libsolv-c50b68298dd430a3cdf58a0c252a890fcdc23dd2.tar.bz2 libsolv-c50b68298dd430a3cdf58a0c252a890fcdc23dd2.zip |
fix instbuddy generation code
we iterated over the wrong array, thus the rpm -> buddy link
did not work.
Diffstat (limited to 'src')
-rw-r--r-- | src/rules.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/rules.c b/src/rules.c index 264a1b7..6b561cc 100644 --- a/src/rules.c +++ b/src/rules.c @@ -496,9 +496,9 @@ addlinks(Solver *solv, Solvable *s, Id req, Queue *qr, Id prv, Queue *qp, Map *m solv->instbuddy = solv_calloc(installed->end - installed->start, sizeof(Id)); if (qr->count == 1) solv->instbuddy[s - pool->solvables - installed->start] = qr->elements[0]; - for (i = 0; i < qp->count; i++) + for (i = 0; i < qr->count; i++) { - Id p = qp->elements[i]; + Id p = qr->elements[i]; if (pool->solvables[p].repo != installed) continue; /* huh? */ if (qp->count > 1 || (solv->instbuddy[p - installed->start] != 0 && solv->instbuddy[p - installed->start] != s - pool->solvables)) |