Chromium Code Reviews| Index: base/process_util_unittest.cc |
| =================================================================== |
| --- base/process_util_unittest.cc (revision 32958) |
| +++ base/process_util_unittest.cc (working copy) |
| @@ -415,10 +415,10 @@ |
| } |
| TEST_F(OutOfMemoryTest, Posix_memalign) { |
| - // The (void) is to prevent a gcc warning about unused return values. |
| - // We don't actually care about the return value, since we're |
| - // asserting death. |
| - ASSERT_DEATH((void) posix_memalign(&value_, 8, test_size_), ""); |
| + // Grab the return value of posix_memalign to silence a compiler warning |
| + // about unused return values. We don't actually care about the return |
| + // value, since we're asserting death. |
| + ASSERT_DEATH(EXPECT_EQ(ENOMEM, posix_memalign(&value_, 8, test_size_)), ""); |
|
willchan no longer on Chromium
2009/11/24 21:12:43
Don't you need to #include <errno.h> for ENOMEM?
|
| } |
| extern "C" { |