Commit 6313a20855bf4a32bd5f3b8e1b35e81ba5d709ad

Edward Thomson 2017-02-26T16:01:32

Merge pull request #4141 from kainjow/patch-2 Fix inet_pton tests triggering an assert in Haiku

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
diff --git a/tests/core/posix.c b/tests/core/posix.c
index 26ae360..018d0c8 100644
--- a/tests/core/posix.c
+++ b/tests/core/posix.c
@@ -94,10 +94,10 @@ void test_core_posix__inet_pton(void)
 	cl_assert(p_inet_pton(AF_INET, "10.foo.bar.1", &addr) == 0);
 
 	/* Test unsupported address families */
-	cl_git_fail(p_inet_pton(12, "52.472", NULL)); /* AF_DECnet */
+	cl_git_fail(p_inet_pton(12, "52.472", &addr)); /* AF_DECnet */
 	cl_assert_equal_i(EAFNOSUPPORT, errno);
 
-	cl_git_fail(p_inet_pton(5, "315.124", NULL)); /* AF_CHAOS */
+	cl_git_fail(p_inet_pton(5, "315.124", &addr)); /* AF_CHAOS */
 	cl_assert_equal_i(EAFNOSUPPORT, errno);
 }