Date: Mon, 8 Nov 2021 19:33:30 GMT From: Ed Maste <emaste@FreeBSD.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org Subject: git: 117844539758 - stable/12 - objcopy: fix stable/12 mismerge Message-ID: <202111081933.1A8JXUIi002670@gitrepo.freebsd.org>
next in thread | raw e-mail | index | archive | help
The branch stable/12 has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=11784453975887ef84f7843248bec90dda701eef commit 11784453975887ef84f7843248bec90dda701eef Author: Ed Maste <emaste@FreeBSD.org> AuthorDate: 2021-11-08 19:30:29 +0000 Commit: Ed Maste <emaste@FreeBSD.org> CommitDate: 2021-11-08 19:32:59 +0000 objcopy: fix stable/12 mismerge Reported by: dim Fixes: 2cd53619a1fc ("strip/objcopy: handle empty file...") Sponsored by: The FreeBSD Foundation --- contrib/elftoolchain/elfcopy/main.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/contrib/elftoolchain/elfcopy/main.c b/contrib/elftoolchain/elfcopy/main.c index ae2d3a2440df..995f031dfa69 100644 --- a/contrib/elftoolchain/elfcopy/main.c +++ b/contrib/elftoolchain/elfcopy/main.c @@ -701,11 +701,12 @@ create_file(struct elfcopy *ecp, const char *src, const char *dst) free(elftemp); } - if ((ecp->ein = elf_begin(ifd, ELF_C_READ, NULL)) == NULL) + if ((ecp->ein = elf_begin(ifd, ELF_C_READ, NULL)) == NULL) { if (fstat(ifd, &sb) == 0 && sb.st_size == 0) errx(EXIT_FAILURE, "file format not recognized"); errx(EXIT_FAILURE, "elf_begin() failed: %s", elf_errmsg(-1)); + } switch (elf_kind(ecp->ein)) { case ELF_K_NONE:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202111081933.1A8JXUIi002670>