[Lldb-commits] [PATCH] D137807: When scanning mach-o corefile, don't run all DynamicLoader plugins letting one of them Create when searching for binaries

Jason Molenda via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Thu Nov 10 15:45:56 PST 2022


jasonmolenda updated this revision to Diff 474624.
jasonmolenda added a comment.

Jonas' feedback


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D137807/new/

https://reviews.llvm.org/D137807

Files:
  lldb/source/Plugins/Process/mach-core/ProcessMachCore.cpp


Index: lldb/source/Plugins/Process/mach-core/ProcessMachCore.cpp
===================================================================
--- lldb/source/Plugins/Process/mach-core/ProcessMachCore.cpp
+++ lldb/source/Plugins/Process/mach-core/ProcessMachCore.cpp
@@ -327,9 +327,11 @@
   // corefile
   core_objfile->LoadCoreFileImages(*this);
 
-  // LoadCoreFileImges may have set the dynamic loader; if we now have
-  // a dynamic loader, save its name so we don't un-set it later.
-  if (GetDynamicLoader())
+  // LoadCoreFileImges may have set the dynamic loader, e.g. in
+  // PlatformDarwinKernel::LoadPlatformBinaryAndSetup().
+  // If we now have a dynamic loader, save its name so we don't 
+  // un-set it later.
+  if (m_dyld_up)
     m_dyld_plugin_name = GetDynamicLoader()->GetPluginName();
 }
 


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D137807.474624.patch
Type: text/x-patch
Size: 803 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20221110/dbe1a127/attachment.bin>


More information about the lldb-commits mailing list