[Lldb-commits] [lldb] r207860 - LLDB_INVALID_ADDRESS may not be too large for a uintptr_t, so cast

Joerg Sonnenberger joerg at bec.de
Fri May 2 11:58:52 PDT 2014


Author: joerg
Date: Fri May  2 13:58:51 2014
New Revision: 207860

URL: http://llvm.org/viewvc/llvm-project?rev=207860&view=rev
Log:
LLDB_INVALID_ADDRESS may not be too large for a uintptr_t, so cast
first.

Modified:
    lldb/trunk/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCRuntimeV2.cpp

Modified: lldb/trunk/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCRuntimeV2.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCRuntimeV2.cpp?rev=207860&r1=207859&r2=207860&view=diff
==============================================================================
--- lldb/trunk/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCRuntimeV2.cpp (original)
+++ lldb/trunk/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCRuntimeV2.cpp Fri May  2 13:58:51 2014
@@ -2582,7 +2582,7 @@ AppleObjCRuntimeV2::TaggedPointerVendorR
         uintptr_t slot_ptr = slot*process->GetAddressByteSize()+m_objc_debug_taggedpointer_classes;
         Error error;
         uintptr_t slot_data = process->ReadPointerFromMemory(slot_ptr, error);
-        if (error.Fail() || slot_data == 0 || slot_data == LLDB_INVALID_ADDRESS)
+        if (error.Fail() || slot_data == 0 || slot_data == uintptr_t(LLDB_INVALID_ADDRESS))
             return nullptr;
         actual_class_descriptor_sp = m_runtime.GetClassDescriptorFromISA((ObjCISA)slot_data);
         if (!actual_class_descriptor_sp)





More information about the lldb-commits mailing list