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 1DB2C138336 for ; Sat, 4 May 2019 11:53:52 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 1F0F3E087C; Sat, 4 May 2019 11:53:51 +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 04892E087C for ; Sat, 4 May 2019 11:53:50 +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 8D834343514 for ; Sat, 4 May 2019 11:53:49 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 34DE35D7 for ; Sat, 4 May 2019 11:53:48 +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: <1556970691.55a3b37772e4e4f70b3eaf76916f2b1450d26a6e.grobian@gentoo> Subject: [gentoo-commits] proj/portage-utils:master commit in: libq/ X-VCS-Repository: proj/portage-utils X-VCS-Files: libq/cache.c X-VCS-Directories: libq/ X-VCS-Committer: grobian X-VCS-Committer-Name: Fabian Groffen X-VCS-Revision: 55a3b37772e4e4f70b3eaf76916f2b1450d26a6e X-VCS-Branch: master Date: Sat, 4 May 2019 11:53:48 +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: 60cbb071-0d1a-4e18-9de2-7bb968239767 X-Archives-Hash: ffe0192d3e14a72992e53d685ea4c5b8 commit: 55a3b37772e4e4f70b3eaf76916f2b1450d26a6e Author: Fabian Groffen gentoo org> AuthorDate: Sat May 4 11:51:31 2019 +0000 Commit: Fabian Groffen gentoo org> CommitDate: Sat May 4 11:51:31 2019 +0000 URL: https://gitweb.gentoo.org/proj/portage-utils.git/commit/?id=55a3b377 libq/cache: probably fix crash from bug #684252#c22 Ensure we renew the local ebuild dir context after we found a problem with the previous directory Bug: https://bugs.gentoo.org/684252 Signed-off-by: Fabian Groffen gentoo.org> libq/cache.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/libq/cache.c b/libq/cache.c index 0dbf483..a8b4ede 100644 --- a/libq/cache.c +++ b/libq/cache.c @@ -163,8 +163,10 @@ cache_next_pkg(cache_cat_ctx *cat_ctx) /* opening might fail if what we found wasn't a * directory or something */ - if (ctx->ebuilddir_cat_ctx == NULL) + if (ctx->ebuilddir_cat_ctx == NULL) { + ctx->ebuilddir_pkg_ctx = NULL; return NULL; + } } ret = q_vdb_next_pkg(ctx->ebuilddir_cat_ctx);