Fix thinko in UnwindTable.cpp where it wouldn't provde a
FuncUnwinders object if the eh_frame section was missing
from an objfile. Worked fine on x86_64 but on i386 where
eh_frame is unusual, that resulted in the arch default
UnwindPlan being used all the time instead of picking up
an assembly profile based unwindplan.
git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@118467 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/source/Symbol/UnwindTable.cpp b/source/Symbol/UnwindTable.cpp
index 7738cba..5356e94 100644
--- a/source/Symbol/UnwindTable.cpp
+++ b/source/Symbol/UnwindTable.cpp
@@ -77,11 +77,6 @@
initialize();
- if (m_eh_frame == NULL)
- {
- return no_unwind_found;
- }
-
// Create a FuncUnwinders object for the binary search below
AddressRange search_range(addr, 1);
FuncUnwindersSP search_unwind(new FuncUnwinders (*this, NULL, search_range));
@@ -111,7 +106,7 @@
if (!sc.GetAddressRange(eSymbolContextFunction | eSymbolContextSymbol, range) || !range.GetBaseAddress().IsValid())
{
// Does the eh_frame unwind info has a function bounds for this addr?
- if (!m_eh_frame->GetAddressRange (addr, range))
+ if (m_eh_frame == NULL || !m_eh_frame->GetAddressRange (addr, range))
{
return no_unwind_found;
}