Bug 913548 part 1: Switch nsExceptionHandler.cpp from (void) to unused<<. r=ted

This commit is contained in:
Daniel Holbert 2013-10-16 16:46:14 -07:00
parent 4bcdaa4727
commit e742bcd2ac

View File

@ -8,6 +8,7 @@
#include "mozilla/dom/CrashReporterChild.h"
#include "mozilla/Services.h"
#include "nsIObserverService.h"
#include "mozilla/unused.h"
#include "mozilla/Util.h"
#include "nsThreadUtils.h"
@ -453,8 +454,7 @@ bool MinidumpCallback(
O_WRONLY | O_CREAT | O_TRUNC,
0600);
if (fd != -1) {
ssize_t ignored = sys_write(fd, minidumpPath, my_strlen(minidumpPath));
(void)ignored;
unused << sys_write(fd, minidumpPath, my_strlen(minidumpPath));
sys_close(fd);
}
#endif
@ -507,8 +507,7 @@ bool MinidumpCallback(
O_WRONLY | O_CREAT | O_TRUNC,
0600);
if (fd != -1) {
ssize_t ignored = sys_write(fd, crashTimeString, crashTimeStringLen);
(void)ignored;
unused << sys_write(fd, crashTimeString, crashTimeStringLen);
sys_close(fd);
}
#endif
@ -676,12 +675,12 @@ bool MinidumpCallback(
// need to clobber this, as libcurl might load NSS,
// and we want it to load the system NSS.
unsetenv("LD_LIBRARY_PATH");
(void) execl(crashReporterPath,
unused << execl(crashReporterPath,
crashReporterPath, minidumpPath, (char*)0);
#else
// Invoke the reportCrash activity using am
if (androidUserSerial) {
(void) execlp("/system/bin/am",
unused << execlp("/system/bin/am",
"/system/bin/am",
"start",
"--user", androidUserSerial,
@ -690,7 +689,7 @@ bool MinidumpCallback(
"--es", "minidumpPath", minidumpPath,
(char*)0);
} else {
(void) execlp("/system/bin/am",
unused << execlp("/system/bin/am",
"/system/bin/am",
"start",
"-a", "org.mozilla.gecko.reportCrash",