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 C69CC1382C5 for ; Wed, 16 Jun 2021 19:21:55 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 28907E0829; Wed, 16 Jun 2021 19:21:55 +0000 (UTC) Received: from smtp.gentoo.org (woodpecker.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (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 12D7AE0829 for ; Wed, 16 Jun 2021 19:21:55 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (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 21F03335D6A for ; Wed, 16 Jun 2021 19:21:54 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 4C72A7B1 for ; Wed, 16 Jun 2021 19:21:51 +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: <1623871184.2d3465b19eafb2577974cb9fa48a3938cdb38925.grobian@gentoo> Subject: [gentoo-commits] proj/portage-utils:master commit in: / X-VCS-Repository: proj/portage-utils X-VCS-Files: qmerge.c X-VCS-Directories: / X-VCS-Committer: grobian X-VCS-Committer-Name: Fabian Groffen X-VCS-Revision: 2d3465b19eafb2577974cb9fa48a3938cdb38925 X-VCS-Branch: master Date: Wed, 16 Jun 2021 19:21:51 +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: fe068e52-7aed-4153-954c-260152ea2f42 X-Archives-Hash: 693375040148dafaef358c0820f6914a commit: 2d3465b19eafb2577974cb9fa48a3938cdb38925 Author: Joakim Tjernlund infinera com> AuthorDate: Wed Jun 16 14:53:00 2021 +0000 Commit: Fabian Groffen gentoo org> CommitDate: Wed Jun 16 19:19:44 2021 +0000 URL: https://gitweb.gentoo.org/proj/portage-utils.git/commit/?id=2d3465b1 qmerge: Protect against another NULL hash Signed-off-by: Joakim Tjernlund infinera.com> Signed-off-by: Fabian Groffen gentoo.org> qmerge.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qmerge.c b/qmerge.c index 583a27e..43f537a 100644 --- a/qmerge.c +++ b/qmerge.c @@ -804,7 +804,7 @@ merge_tree_at(int fd_src, const char *src, int fd_dst, const char *dst, hash = hash_file_at(subfd_src, name, HASH_MD5); if (!pretend) fprintf(contents, "obj %s %s %zu""\n", - cpath, hash, (size_t)st.st_mtime); + cpath, hash ? hash : "xxx", (size_t)st.st_mtime); /* Check CONFIG_PROTECT */ if (config_protected(cpath + eprefix_len,