mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-02-27 12:50:09 +00:00
Bug 1197306 - remove PR_snprintf calls in ipc/; r=froydnj
This commit is contained in:
parent
9fc33ccd15
commit
4482e6ef5c
@ -18,7 +18,7 @@
|
||||
#endif
|
||||
|
||||
#include "MainThreadUtils.h"
|
||||
#include "prprf.h"
|
||||
#include "mozilla/Snprintf.h"
|
||||
#include "prenv.h"
|
||||
#include "nsXPCOMPrivate.h"
|
||||
|
||||
@ -617,8 +617,7 @@ GeckoChildProcessHost::PerformAsyncLaunchInternal(std::vector<std::string>& aExt
|
||||
// send the child the PID so that it can open a ProcessHandle back to us.
|
||||
// probably don't want to do this in the long run
|
||||
char pidstring[32];
|
||||
PR_snprintf(pidstring, sizeof(pidstring) - 1,
|
||||
"%ld", base::Process::Current().pid());
|
||||
snprintf_literal(pidstring,"%d", base::Process::Current().pid());
|
||||
|
||||
const char* const childProcessType =
|
||||
XRE_ChildProcessTypeToString(mProcessType);
|
||||
|
@ -18,8 +18,7 @@
|
||||
#include "nsDebug.h"
|
||||
#include "nsISupportsImpl.h"
|
||||
#include "nsContentUtils.h"
|
||||
|
||||
#include "prprf.h"
|
||||
#include "mozilla/Snprintf.h"
|
||||
|
||||
// Undo the damage done by mozzconf.h
|
||||
#undef compress
|
||||
@ -1691,9 +1690,8 @@ MessageChannel::ReportConnectionError(const char* aChannelName, Message* aMsg) c
|
||||
|
||||
if (aMsg) {
|
||||
char reason[512];
|
||||
PR_snprintf(reason, sizeof(reason),
|
||||
"(msgtype=0x%lX,name=%s) %s",
|
||||
aMsg->type(), aMsg->name(), errorMsg);
|
||||
snprintf_literal(reason,"(msgtype=0x%X,name=%s) %s",
|
||||
aMsg->type(), aMsg->name(), errorMsg);
|
||||
|
||||
PrintErrorMessage(mSide, aChannelName, reason);
|
||||
} else {
|
||||
@ -1737,9 +1735,8 @@ MessageChannel::MaybeHandleError(Result code, const Message& aMsg, const char* c
|
||||
}
|
||||
|
||||
char reason[512];
|
||||
PR_snprintf(reason, sizeof(reason),
|
||||
"(msgtype=0x%lX,name=%s) %s",
|
||||
aMsg.type(), aMsg.name(), errorMsg);
|
||||
snprintf_literal(reason,"(msgtype=0x%X,name=%s) %s",
|
||||
aMsg.type(), aMsg.name(), errorMsg);
|
||||
|
||||
PrintErrorMessage(mSide, channelName, reason);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user