]> git.ipfire.org Git - thirdparty/elfutils.git/commit
src: Check ebl_openbackend result before using ebl handle.
authorMark Wielaard <mark@klomp.org>
Sat, 9 May 2020 19:05:31 +0000 (21:05 +0200)
committerMark Wielaard <mark@klomp.org>
Thu, 14 May 2020 12:30:57 +0000 (14:30 +0200)
commit5d769dd05d2e10dd35dc34e105d6f1f19b57d124
treeec51e51ffea9b85afa526d4ec6c12d8e3a7e5164
parent24d6569408c2039a97054f3e6999cb174c076242
src: Check ebl_openbackend result before using ebl handle.

GCC10 -fanalyzer plus -flto sees that ebl_openbackend can fail and
return NULL. Most of the time we will get a dummy ebl, but in case
of out of memory or corrupt ELF header it might return NULL. Make
sure that we report a (fatal) error in that case in all tools.

Signed-off-by: Mark Wielaard <mark@klomp.org>
src/ChangeLog
src/elflint.c
src/nm.c
src/objdump.c