From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id D3D72138334 for ; Tue, 20 Nov 2018 14:25:58 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id D8EECE09C2; Tue, 20 Nov 2018 14:25:57 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id A65F0E09C2 for ; Tue, 20 Nov 2018 14:25:57 +0000 (UTC) Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id E7585335C7D for ; Tue, 20 Nov 2018 14:25:55 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 049E942E for ; Tue, 20 Nov 2018 14:25:54 +0000 (UTC) From: "Fabian Groffen" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Fabian Groffen" Message-ID: <1542723873.2e83b5bd31ee989b79fbed7d2a9882f98c2771a5.grobian@gentoo> Subject: [gentoo-commits] proj/portage-utils:master commit in: / X-VCS-Repository: proj/portage-utils X-VCS-Files: qdepends.c X-VCS-Directories: / X-VCS-Committer: grobian X-VCS-Committer-Name: Fabian Groffen X-VCS-Revision: 2e83b5bd31ee989b79fbed7d2a9882f98c2771a5 X-VCS-Branch: master Date: Tue, 20 Nov 2018 14:25:54 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: 3cb69e79-48ca-41eb-978f-db04be6bee51 X-Archives-Hash: 97312aa638a51281a55612ae225793dc commit: 2e83b5bd31ee989b79fbed7d2a9882f98c2771a5 Author: Fabian Groffen gentoo org> AuthorDate: Tue Nov 20 14:24:33 2018 +0000 Commit: Fabian Groffen gentoo org> CommitDate: Tue Nov 20 14:24:33 2018 +0000 URL: https://gitweb.gentoo.org/proj/portage-utils.git/commit/?id=2e83b5bd qdepends: match reverse deps without SLOT if not given Continuation of bug #668418, atom_compare is strict about SLOT matches. Bug: https://bugs.gentoo.org/668418 Signed-off-by: Fabian Groffen gentoo.org> qdepends.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/qdepends.c b/qdepends.c index 3ff0ebb..e6b9bcf 100644 --- a/qdepends.c +++ b/qdepends.c @@ -1,9 +1,10 @@ /* - * Copyright 2005-2018 Gentoo Foundation + * Copyright 2005-2018 Gentoo Authors * Distributed under the terms of the GNU General Public License v2 * * Copyright 2005-2010 Ned Ludd - * Copyright 2005-2014 Mike Frysinger - + * Copyright 2018- Fabian Groffen - */ #ifdef APPLET_qdepends @@ -486,6 +487,7 @@ qdepends_vdb_deep_cb(q_vdb_pkg_ctx *pkg_ctx, void *priv) depend_atom *as; depend_atom *ac; char firstmatch = 0; + char *sslot; if (!q_vdb_pkg_eat(pkg_ctx, state->depend_file, &depend, &depend_len)) return 0; @@ -569,7 +571,13 @@ qdepends_vdb_deep_cb(q_vdb_pkg_ctx *pkg_ctx, void *priv) ptr + match.rm_so); ac = atom_explode(qbuf); + /* drop SLOT when not present in aq so we can match atoms + * regardless */ + sslot = ac->SLOT; + if (aq->SLOT == NULL && ac->SLOT != NULL) + ac->SLOT = NULL; ret = atom_compare(ac, aq); + ac->SLOT = sslot; if (ret != EQUAL) { atom_implode(ac); break;