<rdar://problem/12100588>

Don't crash when we can't resolve our stub to a symbol.



git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@163189 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/source/Plugins/ObjectFile/Mach-O/ObjectFileMachO.cpp b/source/Plugins/ObjectFile/Mach-O/ObjectFileMachO.cpp
index 3e2d765..2027535 100644
--- a/source/Plugins/ObjectFile/Mach-O/ObjectFileMachO.cpp
+++ b/source/Plugins/ObjectFile/Mach-O/ObjectFileMachO.cpp
@@ -12,9 +12,11 @@
 
 #include "ObjectFileMachO.h"
 
+#include "lldb/lldb-private-log.h"
 #include "lldb/Core/ArchSpec.h"
 #include "lldb/Core/DataBuffer.h"
 #include "lldb/Core/FileSpecList.h"
+#include "lldb/Core/Log.h"
 #include "lldb/Core/Module.h"
 #include "lldb/Core/PluginManager.h"
 #include "lldb/Core/RangeMap.h"
@@ -3139,7 +3141,6 @@
                                     stub_symbol = symtab->FindSymbolByID (stub_sym_id);
                                 }
 
-                                assert (stub_symbol);
                                 if (stub_symbol)
                                 {
                                     Address so_addr(symbol_stub_addr, section_list);
@@ -3173,6 +3174,11 @@
                                         ++sym_idx;
                                     }
                                 }
+                                else
+                                {
+                                    if (log)
+                                        log->Warning ("symbol stub referencing symbol table symbol %u that isn't in our minimal symbol table, fix this!!!", stub_sym_id);
+                                }
                             }
                         }
                     }