[Openmp-commits] [openmp] 856c995 - [libomptarget] Add missing elf_end call in elf_common.c
via Openmp-commits
openmp-commits at lists.llvm.org
Thu Mar 26 12:07:49 PDT 2020
Author: Jon Chesterfield
Date: 2020-03-26T19:07:33Z
New Revision: 856c99543693138b2365ff84b6ac6f31b0acf394
URL: https://github.com/llvm/llvm-project/commit/856c99543693138b2365ff84b6ac6f31b0acf394
DIFF: https://github.com/llvm/llvm-project/commit/856c99543693138b2365ff84b6ac6f31b0acf394.diff
LOG: [libomptarget] Add missing elf_end call in elf_common.c
Summary:
[libomptarget] Add missing elf_end call in elf_common.c
Noticed when reviewing D76843.
Reviewers: simoll, jdoerfert, efocht, AndreyChurbanov, grokos, manorom
Reviewed By: grokos
Subscribers: openmp-commits
Tags: #openmp
Differential Revision: https://reviews.llvm.org/D76874
Added:
Modified:
openmp/libomptarget/plugins/common/elf_common.c
Removed:
################################################################################
diff --git a/openmp/libomptarget/plugins/common/elf_common.c b/openmp/libomptarget/plugins/common/elf_common.c
index 60e1e4fda480..b0efd1abc148 100644
--- a/openmp/libomptarget/plugins/common/elf_common.c
+++ b/openmp/libomptarget/plugins/common/elf_common.c
@@ -45,6 +45,7 @@ static inline int32_t elf_check_machine(__tgt_device_image *image,
// Check if ELF is the right kind.
if (elf_kind(e) != ELF_K_ELF) {
DP("Unexpected ELF type!\n");
+ elf_end(e);
return 0;
}
Elf64_Ehdr *eh64 = elf64_getehdr(e);
More information about the Openmp-commits
mailing list