gecko-dev/build/build-clang/r313872.patch

19 строки
725 B
Diff

Index: tools/dsymutil/DwarfLinker.cpp
===================================================================
--- a/llvm/tools/dsymutil/DwarfLinker.cpp (revision 313871)
+++ b/llvm/tools/dsymutil/DwarfLinker.cpp (revision 313872)
@@ -1496,7 +1496,11 @@
if ((RefCU = getUnitForOffset(Units, RefOffset)))
- if (const auto RefDie = RefCU->getOrigUnit().getDIEForOffset(RefOffset))
- return RefDie;
+ if (const auto RefDie = RefCU->getOrigUnit().getDIEForOffset(RefOffset)) {
+ // In a file with broken references, an attribute might point to a NULL
+ // DIE.
+ if(!RefDie.isNULL())
+ return RefDie;
+ }
Linker.reportWarning("could not find referenced DIE", &DIE);
return DWARFDie();