]> git.ipfire.org Git - thirdparty/libsolv.git/commitdiff
re-compute 's' pointer while iterating repo solvables in order to cope
authorKlaus Kaempf <kkaempf@suse.de>
Thu, 21 Feb 2008 12:47:41 +0000 (12:47 +0000)
committerKlaus Kaempf <kkaempf@suse.de>
Thu, 21 Feb 2008 12:47:41 +0000 (12:47 +0000)
with re-allocs happening inside the loop body.

src/repo.h

index 6b823fb5109c6ddd78e4d448cd33c6121abe2fb1..a64154158f4b6dd85a6d9e045dac6cb1630bfa7e 100644 (file)
@@ -132,7 +132,7 @@ static inline void repo_free_solvable_block(Repo *repo, Id start, int count, int
 }
 
 #define FOR_REPO_SOLVABLES(r, p, s)                                            \
-  for (p = (r)->start, s = (r)->pool->solvables + p; p < (r)->end; p++, s++)   \
+  for (p = (r)->start, s = (r)->pool->solvables + p; p < (r)->end; p++, s = (r)->pool->solvables + p)  \
     if (s->repo == (r))