diff options
author | Tom Eccles <tom.eccles@codethink.co.uk> | 2022-04-22 13:03:28 -0400 |
---|---|---|
committer | Aaron Ballman <aaron@aaronballman.com> | 2022-04-22 13:03:28 -0400 |
commit | 225b91e6cbba31ff1ce787a152a67977d08fdcab (patch) | |
tree | 53a9fcf52bd965fad88b9b21655b3cb7c2fb5faf /llvm/tools/llvm-objcopy/llvm-objcopy.cpp | |
parent | e9a902c7f755a378e197c4b246a32859c0ee162d (diff) | |
download | llvm-225b91e6cbba31ff1ce787a152a67977d08fdcab.zip llvm-225b91e6cbba31ff1ce787a152a67977d08fdcab.tar.gz llvm-225b91e6cbba31ff1ce787a152a67977d08fdcab.tar.bz2 |
Fix crash getting name of a template decl
NamedDecl::getIdentifier can return a nullptr when
DeclarationName::isIdentifier is false, which leads to a null pointer
dereference when TypePrinter::printTemplateId calls ->getName().
NamedDecl::getName does the same thing in the successful case and
returns an empty string in the failure case.
This crash affects the llvm 14 packages on llvm.org.
Diffstat (limited to 'llvm/tools/llvm-objcopy/llvm-objcopy.cpp')
0 files changed, 0 insertions, 0 deletions