[Lldb-commits] [lldb] r217287 - Added logging of the POSIX-DYLD rendezvous address (i.e. the info_location address)
Todd Fiala
todd.fiala at gmail.com
Fri Sep 5 15:28:41 PDT 2014
Author: tfiala
Date: Fri Sep 5 17:28:40 2014
New Revision: 217287
URL: http://llvm.org/viewvc/llvm-project?rev=217287&view=rev
Log:
Added logging of the POSIX-DYLD rendezvous address (i.e. the info_location address)
Modified:
lldb/trunk/source/Plugins/DynamicLoader/POSIX-DYLD/DYLDRendezvous.cpp
Modified: lldb/trunk/source/Plugins/DynamicLoader/POSIX-DYLD/DYLDRendezvous.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/DynamicLoader/POSIX-DYLD/DYLDRendezvous.cpp?rev=217287&r1=217286&r2=217287&view=diff
==============================================================================
--- lldb/trunk/source/Plugins/DynamicLoader/POSIX-DYLD/DYLDRendezvous.cpp (original)
+++ lldb/trunk/source/Plugins/DynamicLoader/POSIX-DYLD/DYLDRendezvous.cpp Fri Sep 5 17:28:40 2014
@@ -34,6 +34,13 @@ ResolveRendezvousAddress(Process *proces
addr_t info_addr;
Error error;
+ if (!process)
+ {
+ if (log)
+ log->Printf ("%s null process provided", __FUNCTION__);
+ return LLDB_INVALID_ADDRESS;
+ }
+
// Try to get it from our process. This might be a remote process and might
// grab it via some remote-specific mechanism.
info_location = process->GetImageInfoAddress();
@@ -43,7 +50,7 @@ ResolveRendezvousAddress(Process *proces
// If the process fails to return an address, fall back to seeing if the local object file can help us find it.
if (info_location == LLDB_INVALID_ADDRESS)
{
- Target *target = process ? &process->GetTarget() : nullptr;
+ Target *target = &process->GetTarget();
if (target)
{
ObjectFile *obj_file = target->GetExecutableModule()->GetObjectFile();
@@ -70,6 +77,9 @@ ResolveRendezvousAddress(Process *proces
return LLDB_INVALID_ADDRESS;
}
+ if (log)
+ log->Printf ("%s reading pointer (%" PRIu32 " bytes) from 0x%" PRIx64, __FUNCTION__, process->GetAddressByteSize(), info_location);
+
info_addr = process->ReadPointerFromMemory(info_location, error);
if (error.Fail())
{
More information about the lldb-commits
mailing list