[PATCH] D78736: [DWARF5]: Added support for dumping strx forms in llvm-dwarfdump
Sourabh Singh Tomar via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Apr 28 09:06:41 PDT 2020
SouraVX marked 5 inline comments as done.
SouraVX added inline comments.
================
Comment at: llvm/lib/DebugInfo/DWARF/DWARFDebugMacro.cpp:154
StrOffset = Data.getRelocatedValue(/*OffsetSize=*/4, &Offset);
- E.MacroStr = StringExtractor.getCStr(&StrOffset);
+ assert(StringExtractor && "String Extractor not found");
+ E.MacroStr = StringExtractor->getCStr(&StrOffset);
----------------
ikudrin wrote:
> `assert` should not be used for the cases when malicious user input may trigger it.
This `String Extractor` is innocuous in a sense, it is passed as parameters by functions up in the stack. So I left this ``assert` as it is. ? Are you okay with this.
Other asserts, I've replaced with error handling.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D78736/new/
https://reviews.llvm.org/D78736
More information about the llvm-commits
mailing list