[PATCH] D93754: [obj2yaml] - Fix the crash in getUniquedSectionName().
George Rimar via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Dec 23 03:01:45 PST 2020
grimar created this revision.
grimar added reviewers: jhenderson, MaskRay.
Herald added a subscriber: emaste.
Herald added a reviewer: espindola.
grimar requested review of this revision.
Herald added a project: LLVM.
`getUniquedSectionName(const Elf_Shdr *Sec)` assumes that
`Sec` is not `nullptr`.
I've found one place in `getUniquedSymbolName` where it is
not true (because of that we crash when trying to dump
unnamed null section symbols).
Patch fixes the crash and changes the signature of the
`getUniquedSectionName` section to accept a reference.
https://reviews.llvm.org/D93754
Files:
llvm/test/tools/obj2yaml/ELF/symbol.yaml
llvm/tools/obj2yaml/elf2yaml.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D93754.313524.patch
Type: text/x-patch
Size: 5275 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20201223/5a8254cc/attachment.bin>
More information about the llvm-commits
mailing list