]> granicus.if.org Git - llvm/commitdiff
Fix un-initialized error introduced by r291959.
authorDaniel Jasper <djasper@google.com>
Sun, 15 Jan 2017 16:42:36 +0000 (16:42 +0000)
committerDaniel Jasper <djasper@google.com>
Sun, 15 Jan 2017 16:42:36 +0000 (16:42 +0000)
This is uncovered when running tools/dsymutil/X86/empty_range.s.test
with ASAN. Haven't investigate yet, whether that means there is an ODR
violation in that test.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@292065 91177308-0d34-0410-b5e6-96231b3b80d8

tools/dsymutil/DwarfLinker.cpp

index a4033ce30897dceb55d29a7d57e28ec4f6dc0621..2fe4f29d40858e0579d62d9b23d64a4552239bdd 100644 (file)
@@ -211,6 +211,8 @@ public:
                              *Lang == dwarf::DW_LANG_C_plus_plus_11 ||
                              *Lang == dwarf::DW_LANG_C_plus_plus_14 ||
                              *Lang == dwarf::DW_LANG_ObjC_plus_plus);
+    else
+      HasODR = false;
   }
 
   DWARFUnit &getOrigUnit() const { return OrigUnit; }