[Lldb-commits] [lldb] r269598 - Fix a few -Wformat-pedantic warnings

Saleem Abdulrasool via lldb-commits lldb-commits at lists.llvm.org
Sun May 15 11:18:13 PDT 2016


Author: compnerd
Date: Sun May 15 13:18:13 2016
New Revision: 269598

URL: http://llvm.org/viewvc/llvm-project?rev=269598&view=rev
Log:
Fix a few -Wformat-pedantic warnings

Clean up some newly introduced -Wformat-pedantic warnings (%p expects a void *).

Modified:
    lldb/trunk/source/Core/Listener.cpp
    lldb/trunk/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp

Modified: lldb/trunk/source/Core/Listener.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Core/Listener.cpp?rev=269598&r1=269597&r2=269598&view=diff
==============================================================================
--- lldb/trunk/source/Core/Listener.cpp (original)
+++ lldb/trunk/source/Core/Listener.cpp Sun May 15 13:18:13 2016
@@ -60,7 +60,7 @@ Listener::~Listener()
     Clear();
 
     if (log)
-        log->Printf("%p Listener::%s('%s')", this, __FUNCTION__, m_name.c_str());
+        log->Printf("%p Listener::%s('%s')", static_cast<void *>(this), __FUNCTION__, m_name.c_str());
 }
 
 void
@@ -89,7 +89,7 @@ Listener::Clear()
     }
 
     if (log)
-        log->Printf("%p Listener::%s('%s')", this, __FUNCTION__, m_name.c_str());
+        log->Printf("%p Listener::%s('%s')", static_cast<void *>(this), __FUNCTION__, m_name.c_str());
 }
 
 uint32_t

Modified: lldb/trunk/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp?rev=269598&r1=269597&r2=269598&view=diff
==============================================================================
--- lldb/trunk/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp (original)
+++ lldb/trunk/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp Sun May 15 13:18:13 2016
@@ -3678,7 +3678,7 @@ ProcessGDBRemote::MonitorDebugserverProc
 
     std::shared_ptr<ProcessGDBRemote> process_sp = process_wp.lock();
     if (log)
-        log->Printf("ProcessGDBRemote::%s(process = %p)", __FUNCTION__, process_sp.get());
+        log->Printf("ProcessGDBRemote::%s(process = %p)", __FUNCTION__, static_cast<void *>(process_sp.get()));
     if (!process_sp || process_sp->m_debugserver_pid != debugserver_pid)
         return handled;
 




More information about the lldb-commits mailing list