Fixed io_test to expect a successful return value from pipe(). Verify that pipe() did not fail before trying to use the resulting pipe.
Signed-off-by: David Mackey <tdmac...@booleanhaiku.com> From: David Mackey <tdmac...@booleanhaiku.com> Review: https://reviews.apache.org/r/14245 Project: http://git-wip-us.apache.org/repos/asf/mesos/repo Commit: http://git-wip-us.apache.org/repos/asf/mesos/commit/b60eb983 Tree: http://git-wip-us.apache.org/repos/asf/mesos/tree/b60eb983 Diff: http://git-wip-us.apache.org/repos/asf/mesos/diff/b60eb983 Branch: refs/heads/master Commit: b60eb983f7b43dcb1611d30e9c65651ffac3aeea Parents: c1189c0 Author: Benjamin Mahler <bmah...@twitter.com> Authored: Mon Sep 23 16:27:42 2013 -0700 Committer: Benjamin Mahler <bmah...@twitter.com> Committed: Mon Sep 23 16:27:42 2013 -0700 ---------------------------------------------------------------------- 3rdparty/libprocess/src/tests/io_tests.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/mesos/blob/b60eb983/3rdparty/libprocess/src/tests/io_tests.cpp ---------------------------------------------------------------------- diff --git a/3rdparty/libprocess/src/tests/io_tests.cpp b/3rdparty/libprocess/src/tests/io_tests.cpp index c20d992..ee5b0b4 100644 --- a/3rdparty/libprocess/src/tests/io_tests.cpp +++ b/3rdparty/libprocess/src/tests/io_tests.cpp @@ -21,7 +21,7 @@ TEST(IO, Poll) ASSERT_TRUE(GTEST_IS_THREADSAFE); int pipes[2]; - pipe(pipes); + ASSERT_NE(-1, pipe(pipes)); Future<short> future = io::poll(pipes[0], io::READ);