summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorylavic <ylavic@13f79535-47bb-0310-9956-ffa450edef68>2022-06-23 00:12:43 +0000
committerylavic <ylavic@13f79535-47bb-0310-9956-ffa450edef68>2022-06-23 00:12:43 +0000
commit83bd4d3bce007e47e40a3808bc27e5054379ec89 (patch)
tree9d2d4fd7501a408c738fe81f5be3615264cfc29a
parent85c5b536e3b7e2d1a6a1fd5f6353d8751b21a2e4 (diff)
downloadlibapr-83bd4d3bce007e47e40a3808bc27e5054379ec89.tar.gz
test/testfile.c: apr_file_datasync() fails with ENOTSUP for streams on macos.
* test/testfile.c(test_datasync_on_stream): Handle ENOTSUP on macos. git-svn-id: https://svn.apache.org/repos/asf/apr/apr/trunk@1902180 13f79535-47bb-0310-9956-ffa450edef68
-rw-r--r--test/testfile.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/test/testfile.c b/test/testfile.c
index f48e38857..591f7acb5 100644
--- a/test/testfile.c
+++ b/test/testfile.c
@@ -2240,7 +2240,11 @@ static void test_datasync_on_stream(abts_case *tc, void *data)
APR_ASSERT_SUCCESS(tc, "write to stdout", rv);
rv = apr_file_datasync(f);
if (rv != APR_SUCCESS) {
+#if defined(__APPLE__)
+ ABTS_INT_EQUAL(tc, ENOTSUP, rv);
+#else
ABTS_INT_EQUAL(tc, APR_EINVAL, rv);
+#endif
}
}