summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTim Hammerquist <penryu@apple.com>2017-03-07 21:26:04 +0000
committerTim Hammerquist <penryu@apple.com>2017-03-07 21:26:04 +0000
commita64fafc7b666fd4ea94b1c733f277903b7bd3fdb (patch)
treebdf6b56d8895b98342313ad6ce19c98270f776ae
parent15467df98296cb341bc900176b7766e9994f521c (diff)
downloadbcm5719-llvm-a64fafc7b666fd4ea94b1c733f277903b7bd3fdb.tar.gz
bcm5719-llvm-a64fafc7b666fd4ea94b1c733f277903b7bd3fdb.zip
fix format specifier warnings
llvm-svn: 297228
-rw-r--r--lldb/tools/debugserver/source/MacOSX/DarwinLog/DarwinLogCollector.cpp2
-rw-r--r--lldb/tools/debugserver/source/MacOSX/MachProcess.mm31
-rw-r--r--lldb/tools/debugserver/source/MacOSX/MachThread.cpp2
3 files changed, 21 insertions, 14 deletions
diff --git a/lldb/tools/debugserver/source/MacOSX/DarwinLog/DarwinLogCollector.cpp b/lldb/tools/debugserver/source/MacOSX/DarwinLog/DarwinLogCollector.cpp
index 9c81851c444..1e833c4cb16 100644
--- a/lldb/tools/debugserver/source/MacOSX/DarwinLog/DarwinLogCollector.cpp
+++ b/lldb/tools/debugserver/source/MacOSX/DarwinLog/DarwinLogCollector.cpp
@@ -692,7 +692,7 @@ void DarwinLogCollector::CancelActivityStream() {
DNBLogThreadedIf(LOG_DARWIN_LOG, "DarwinLogCollector::%s(): canceling "
"activity stream %p",
- __FUNCTION__, m_activity_stream);
+ __FUNCTION__, reinterpret_cast<void *>(m_activity_stream));
(*s_os_activity_stream_cancel)(m_activity_stream);
m_activity_stream = nullptr;
}
diff --git a/lldb/tools/debugserver/source/MacOSX/MachProcess.mm b/lldb/tools/debugserver/source/MacOSX/MachProcess.mm
index 720f6bc8899..0daaca1db37 100644
--- a/lldb/tools/debugserver/source/MacOSX/MachProcess.mm
+++ b/lldb/tools/debugserver/source/MacOSX/MachProcess.mm
@@ -1269,7 +1269,7 @@ bool MachProcess::Interrupt() {
bool MachProcess::Signal(int signal, const struct timespec *timeout_abstime) {
DNBLogThreadedIf(LOG_PROCESS,
"MachProcess::Signal (signal = %d, timeout = %p)", signal,
- timeout_abstime);
+ reinterpret_cast<const void *>(timeout_abstime));
nub_state_t state = GetState();
if (::kill(ProcessID(), signal) == 0) {
// If we were running and we have a timeout, wait for the signal to stop
@@ -1277,20 +1277,21 @@ bool MachProcess::Signal(int signal, const struct timespec *timeout_abstime) {
DNBLogThreadedIf(LOG_PROCESS, "MachProcess::Signal (signal = %d, timeout "
"= %p) waiting for signal to stop "
"process...",
- signal, timeout_abstime);
+ signal, reinterpret_cast<const void *>(timeout_abstime));
m_private_events.WaitForSetEvents(eEventProcessStoppedStateChanged,
timeout_abstime);
state = GetState();
DNBLogThreadedIf(
LOG_PROCESS,
"MachProcess::Signal (signal = %d, timeout = %p) state = %s", signal,
- timeout_abstime, DNBStateAsString(state));
+ reinterpret_cast<const void *>(timeout_abstime),
+ DNBStateAsString(state));
return !IsRunning(state);
}
DNBLogThreadedIf(
LOG_PROCESS,
"MachProcess::Signal (signal = %d, timeout = %p) not waiting...",
- signal, timeout_abstime);
+ signal, reinterpret_cast<const void *>(timeout_abstime));
return true;
}
DNBError err(errno, DNBError::POSIX);
@@ -1596,7 +1597,8 @@ DNBBreakpoint *MachProcess::CreateBreakpoint(nub_addr_t addr, nub_size_t length,
if (EnableBreakpoint(addr)) {
DNBLogThreadedIf(LOG_BREAKPOINTS, "MachProcess::CreateBreakpoint ( addr = "
"0x%8.8llx, length = %llu) => %p",
- (uint64_t)addr, (uint64_t)length, bp);
+ (uint64_t)addr, (uint64_t)length,
+ reinterpret_cast<void *>(bp));
return bp;
} else if (bp->Release() == 0) {
m_breakpoints.Remove(addr);
@@ -1627,7 +1629,8 @@ DNBBreakpoint *MachProcess::CreateWatchpoint(nub_addr_t addr, nub_size_t length,
if (EnableWatchpoint(addr)) {
DNBLogThreadedIf(LOG_WATCHPOINTS, "MachProcess::CreateWatchpoint ( addr = "
"0x%8.8llx, length = %llu) => %p",
- (uint64_t)addr, (uint64_t)length, wp);
+ (uint64_t)addr, (uint64_t)length,
+ reinterpret_cast<void *>(wp));
return wp;
} else {
DNBLogThreadedIf(LOG_WATCHPOINTS, "MachProcess::CreateWatchpoint ( addr = "
@@ -2156,7 +2159,7 @@ void MachProcess::AppendSTDOUT(char *s, size_t len) {
size_t MachProcess::GetAvailableSTDOUT(char *buf, size_t buf_size) {
DNBLogThreadedIf(LOG_PROCESS, "MachProcess::%s (&%p[%llu]) ...", __FUNCTION__,
- buf, (uint64_t)buf_size);
+ reinterpret_cast<void *>(buf), (uint64_t)buf_size);
PTHREAD_MUTEX_LOCKER(locker, m_stdio_mutex);
size_t bytes_available = m_stdout_data.size();
if (bytes_available > 0) {
@@ -2316,7 +2319,7 @@ void MachProcess::SignalAsyncProfileData(const char *info) {
size_t MachProcess::GetAsyncProfileData(char *buf, size_t buf_size) {
DNBLogThreadedIf(LOG_PROCESS, "MachProcess::%s (&%p[%llu]) ...", __FUNCTION__,
- buf, (uint64_t)buf_size);
+ reinterpret_cast<void *>(buf), (uint64_t)buf_size);
PTHREAD_MUTEX_LOCKER(locker, m_profile_data_mutex);
if (m_profile_data.empty())
return 0;
@@ -2839,9 +2842,12 @@ pid_t MachProcess::LaunchForDebug(
// Clear out and clean up from any current state
Clear();
- DNBLogThreadedIf(LOG_PROCESS, "%s( path = '%s', argv = %p, envp = %p, "
- "launch_flavor = %u, disable_aslr = %d )",
- __FUNCTION__, path, argv, envp, launch_flavor, disable_aslr);
+ DNBLogThreadedIf(LOG_PROCESS,
+ "%s( path = '%s', argv = %p, envp = %p, "
+ "launch_flavor = %u, disable_aslr = %d )",
+ __FUNCTION__, path, reinterpret_cast<const void *>(argv),
+ reinterpret_cast<const void *>(envp), launch_flavor,
+ disable_aslr);
// Fork a child process for debugging
SetState(eStateLaunching);
@@ -2984,7 +2990,8 @@ pid_t MachProcess::PosixSpawnChildForPTraceDebugging(
DNBLogThreadedIf(LOG_PROCESS, "%s ( path='%s', argv=%p, envp=%p, "
"working_dir=%s, stdin=%s, stdout=%s "
"stderr=%s, no-stdio=%i)",
- __FUNCTION__, path, argv, envp, working_directory,
+ __FUNCTION__, path, reinterpret_cast<const void *>(argv),
+ reinterpret_cast<const void *>(envp), working_directory,
stdin_path, stdout_path, stderr_path, no_stdio);
err.SetError(::posix_spawnattr_init(&attr), DNBError::POSIX);
diff --git a/lldb/tools/debugserver/source/MacOSX/MachThread.cpp b/lldb/tools/debugserver/source/MacOSX/MachThread.cpp
index 36aa8c04bf2..5686e42e4a4 100644
--- a/lldb/tools/debugserver/source/MacOSX/MachThread.cpp
+++ b/lldb/tools/debugserver/source/MacOSX/MachThread.cpp
@@ -50,7 +50,7 @@ MachThread::MachThread(MachProcess *process, bool is_64_bit,
DNBLogThreadedIf(LOG_THREAD | LOG_VERBOSE,
"MachThread::MachThread ( process = %p, tid = 0x%8.8" PRIx64
", seq_id = %u )",
- &m_process, m_unique_id, m_seq_id);
+ reinterpret_cast<void *>(&m_process), m_unique_id, m_seq_id);
}
MachThread::~MachThread() {
OpenPOWER on IntegriCloud