[Lldb-commits] [lldb] r233714 - Fix DynamicLoaderMacOSXDYLD to deal with new shared cache changes.

Greg Clayton gclayton at apple.com
Tue Mar 31 10:02:36 PDT 2015


Author: gclayton
Date: Tue Mar 31 12:02:36 2015
New Revision: 233714

URL: http://llvm.org/viewvc/llvm-project?rev=233714&view=rev
Log:
Fix DynamicLoaderMacOSXDYLD to deal with new shared cache changes.

<rdar://problem/20357466>


Modified:
    lldb/trunk/source/Plugins/DynamicLoader/MacOSX-DYLD/DynamicLoaderMacOSXDYLD.cpp

Modified: lldb/trunk/source/Plugins/DynamicLoader/MacOSX-DYLD/DynamicLoaderMacOSXDYLD.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/DynamicLoader/MacOSX-DYLD/DynamicLoaderMacOSXDYLD.cpp?rev=233714&r1=233713&r2=233714&view=diff
==============================================================================
--- lldb/trunk/source/Plugins/DynamicLoader/MacOSX-DYLD/DynamicLoaderMacOSXDYLD.cpp (original)
+++ lldb/trunk/source/Plugins/DynamicLoader/MacOSX-DYLD/DynamicLoaderMacOSXDYLD.cpp Tue Mar 31 12:02:36 2015
@@ -1266,7 +1266,7 @@ DynamicLoaderMacOSXDYLD::ParseLoadComman
         // Iterate through the object file sections to find the
         // first section that starts of file offset zero and that
         // has bytes in the file...
-        if (dylib_info.segments[i].fileoff == 0 && dylib_info.segments[i].filesize > 0)
+        if ((dylib_info.segments[i].fileoff == 0 && dylib_info.segments[i].filesize > 0) || (dylib_info.segments[i].name == ConstString("__TEXT")))
         {
             dylib_info.slide = dylib_info.address - dylib_info.segments[i].vmaddr;
             // We have found the slide amount, so we can exit





More information about the lldb-commits mailing list