Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1559)

Unified Diff: base/process_util_unittest.cc

Issue 422003: linux: fix a warning in the process_util unittest (Closed)
Patch Set: Created 11 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/process_util_unittest.cc
diff --git a/base/process_util_unittest.cc b/base/process_util_unittest.cc
index 4169dc6b1ec26a5dc9cfcf95aff8744adfd8a62e..e60f923c52d3e3259ba0115df50c2293f782373c 100644
--- a/base/process_util_unittest.cc
+++ b/base/process_util_unittest.cc
@@ -415,7 +415,11 @@ TEST_F(OutOfMemoryTest, Memalign) {
}
TEST_F(OutOfMemoryTest, Posix_memalign) {
- ASSERT_DEATH(posix_memalign(&value_, 8, test_size_), "");
+ // Grab the return value of posix_memalign to silence a compiler
+ // warning about unused variables. We don't actually care about
+ // the return value, since we're asserting death.
+ int ret;
+ ASSERT_DEATH(ret = posix_memalign(&value_, 8, test_size_), "");
}
extern "C" {
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698