aboutsummaryrefslogtreecommitdiff
path: root/lldb/source/Commands/CommandObjectProcess.cpp
diff options
context:
space:
mode:
authorJason Molenda <jmolenda@apple.com>2011-09-20 21:44:10 +0000
committerJason Molenda <jmolenda@apple.com>2011-09-20 21:44:10 +0000
commitfd54b368ea4d1bd481ac4d203362c2a5556418d0 (patch)
tree3adaaf91c485565d39e32762804b69439977c8fd /lldb/source/Commands/CommandObjectProcess.cpp
parent33e91a6cf7a66b83b29e842268bf9b0a1ef14711 (diff)
downloadllvm-fd54b368ea4d1bd481ac4d203362c2a5556418d0.zip
llvm-fd54b368ea4d1bd481ac4d203362c2a5556418d0.tar.gz
llvm-fd54b368ea4d1bd481ac4d203362c2a5556418d0.tar.bz2
Update declarations for all functions/methods that accept printf-style
stdarg formats to use __attribute__ format so the compiler can flag incorrect uses. Fix all incorrect uses. Most of these are innocuous, a few were resulting in crashes. llvm-svn: 140185
Diffstat (limited to 'lldb/source/Commands/CommandObjectProcess.cpp')
-rw-r--r--lldb/source/Commands/CommandObjectProcess.cpp19
1 files changed, 8 insertions, 11 deletions
diff --git a/lldb/source/Commands/CommandObjectProcess.cpp b/lldb/source/Commands/CommandObjectProcess.cpp
index 2f5c1b2..3145984 100644
--- a/lldb/source/Commands/CommandObjectProcess.cpp
+++ b/lldb/source/Commands/CommandObjectProcess.cpp
@@ -610,7 +610,7 @@ public:
if (command.GetArgumentCount())
{
- result.AppendErrorWithFormat("Invalid arguments for '%s'.\nUsage: \n", m_cmd_name.c_str(), m_cmd_syntax.c_str());
+ result.AppendErrorWithFormat("Invalid arguments for '%s'.\nUsage: %s\n", m_cmd_name.c_str(), m_cmd_syntax.c_str());
result.SetStatus (eReturnStatusFailed);
}
else
@@ -733,9 +733,7 @@ public:
}
else
{
- result.AppendErrorWithFormat ("No PID specified for attach\n",
- attach_pid,
- error.AsCString());
+ result.AppendErrorWithFormat ("No PID specified for attach\n");
result.SetStatus (eReturnStatusFailed);
}
@@ -1081,15 +1079,14 @@ public:
}
else
{
- result.AppendErrorWithFormat ("Unable to find process plug-in for remote URL '%s'.\nPlease specify a process plug-in name with the --plugin option, or specify an object file using the \"file\" command: \n",
- m_cmd_name.c_str(),
- m_cmd_syntax.c_str());
+ result.AppendErrorWithFormat ("Unable to find process plug-in for remote URL '%s'.\nPlease specify a process plug-in name with the --plugin option, or specify an object file using the \"file\" command.\n",
+ m_cmd_name.c_str());
result.SetStatus (eReturnStatusFailed);
}
}
else
{
- result.AppendErrorWithFormat ("'%s' takes exactly one argument:\nUsage: \n",
+ result.AppendErrorWithFormat ("'%s' takes exactly one argument:\nUsage: %s\n",
m_cmd_name.c_str(),
m_cmd_syntax.c_str());
result.SetStatus (eReturnStatusFailed);
@@ -1317,7 +1314,7 @@ public:
}
else
{
- result.AppendErrorWithFormat("'%s' takes exactly one signal number argument:\nUsage: \n", m_cmd_name.c_str(),
+ result.AppendErrorWithFormat("'%s' takes exactly one signal number argument:\nUsage: %s\n", m_cmd_name.c_str(),
m_cmd_syntax.c_str());
result.SetStatus (eReturnStatusFailed);
}
@@ -1380,7 +1377,7 @@ public:
}
else
{
- result.AppendErrorWithFormat("'%s' takes no arguments:\nUsage: \n",
+ result.AppendErrorWithFormat("'%s' takes no arguments:\nUsage: %s\n",
m_cmd_name.c_str(),
m_cmd_syntax.c_str());
result.SetStatus (eReturnStatusFailed);
@@ -1438,7 +1435,7 @@ public:
}
else
{
- result.AppendErrorWithFormat("'%s' takes no arguments:\nUsage: \n",
+ result.AppendErrorWithFormat("'%s' takes no arguments:\nUsage: %s\n",
m_cmd_name.c_str(),
m_cmd_syntax.c_str());
result.SetStatus (eReturnStatusFailed);