summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Ritter <tom@mozilla.com>2017-10-09 00:26:16 -0500
committerTom Ritter <tom@mozilla.com>2017-10-09 00:26:16 -0500
commitdb0c8b1da334830b9121fca1e7fe34b010f24460 (patch)
tree2c5ca64734db784da1ce2e9564a8997365bc6627
parent07f3fc26cf00b85de1dd0193cc84ce45a2a3a319 (diff)
downloadnss-hg-db0c8b1da334830b9121fca1e7fe34b010f24460.tar.gz
Bug 1406687 Pass return values from fwrite to Unused to silence the warn-unused-result warning r=njn
MozReview-Commit-ID: 4v6tPF5aMz7
-rw-r--r--lib/mozpkix/test/lib/pkixtestutil.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/mozpkix/test/lib/pkixtestutil.cpp b/lib/mozpkix/test/lib/pkixtestutil.cpp
index ddc8cd082..8f365b329 100644
--- a/lib/mozpkix/test/lib/pkixtestutil.cpp
+++ b/lib/mozpkix/test/lib/pkixtestutil.cpp
@@ -34,6 +34,8 @@
#include "pkixder.h"
#include "pkixutil.h"
+#include "mozilla/Unused.h"
+
using namespace std;
namespace mozilla { namespace pkix { namespace test {
@@ -509,7 +511,7 @@ MaybeLogOutput(const ByteString& result, const char* suffix)
++counter;
ScopedFILE file(OpenFile(logPath, filename, "wb"));
if (file) {
- (void) fwrite(result.data(), result.length(), 1, file.get());
+ Unused << fwrite(result.data(), result.length(), 1, file.get());
}
}
}