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 4EBF6158018 for ; Sun, 3 Oct 2021 08:54:52 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 8FEB9E08EB; Sun, 3 Oct 2021 08:54:51 +0000 (UTC) Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-CHACHA20-POLY1305 (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 77C6DE08EB for ; Sun, 3 Oct 2021 08:54:51 +0000 (UTC) Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84]) (using TLSv1.2 with cipher ECDHE-RSA-CHACHA20-POLY1305 (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 82821342E5E for ; Sun, 3 Oct 2021 08:54:50 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 1FCCC83 for ; Sun, 3 Oct 2021 08:54:49 +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: <1633247999.a6538b5c52f822dc3d67c53ddcda475cd0610d33.grobian@gentoo> Subject: [gentoo-commits] proj/portage-utils:master commit in: / X-VCS-Repository: proj/portage-utils X-VCS-Files: qpkg.c X-VCS-Directories: / X-VCS-Committer: grobian X-VCS-Committer-Name: Fabian Groffen X-VCS-Revision: a6538b5c52f822dc3d67c53ddcda475cd0610d33 X-VCS-Branch: master Date: Sun, 3 Oct 2021 08:54:49 +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-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: 83d9f564-9bfd-4d72-805c-193fd8e62ab8 X-Archives-Hash: e3fc245af3e5aa58d1a225f7a2a5b3c3 commit: a6538b5c52f822dc3d67c53ddcda475cd0610d33 Author: Fabian Groffen gentoo org> AuthorDate: Sun Oct 3 07:59:59 2021 +0000 Commit: Fabian Groffen gentoo org> CommitDate: Sun Oct 3 07:59:59 2021 +0000 URL: https://gitweb.gentoo.org/proj/portage-utils.git/commit/?id=a6538b5c qpkg.c: fix crash on empty PKGDIR, bug #815622 Signed-off-by: Fabian Groffen gentoo.org> qpkg.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/qpkg.c b/qpkg.c index 533e05c..7da0263 100644 --- a/qpkg.c +++ b/qpkg.c @@ -76,6 +76,8 @@ qpkg_clean(char *dirp) return 1; bin_pkgs = tree_get_atoms(pkgs, true, bin_pkgs); + if (bin_pkgs == NULL) + return 1; array_set(bin_pkgs, bins); if (eclean) {