commit: 2cff8ef68b128ffe8f2074a6a8a58795ab7f06b4
Author: Fabian Groffen <grobian <AT> gentoo <DOT> org>
AuthorDate: Sat Mar 13 12:42:58 2021 +0000
Commit: Fabian Groffen <grobian <AT> gentoo <DOT> org>
CommitDate: Sat Mar 13 12:42:58 2021 +0000
URL: https://gitweb.gentoo.org/proj/portage-utils.git/commit/?id=2cff8ef6
libq/tree: fix tree_match_atom when returning newest match
we were not evaluating any versions after the first we've seen for each
package, disallowing us to match any but the most recent version
Signed-off-by: Fabian Groffen <grobian <AT> gentoo.org>
libq/tree.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/libq/tree.c b/libq/tree.c
index 9b06720..a947735 100644
--- a/libq/tree.c
+++ b/libq/tree.c
@@ -1758,8 +1758,8 @@ tree_match_atom(tree_ctx *ctx, depend_atom *query, int
flags)
n->meta = tree_pkg_read(pkg_ctx); \
n->next = ret; \
ret = n; \
+ lastpn = atom->PN; \
} \
- lastpn = atom->PN; \
if (flags & TREE_MATCH_FIRST && ret != NULL) \
break; \
} \