glib/tests/unix: Mostly pass O_CLOEXEC to g_unix_pipe_open()

Using FD_CLOEXEC here is now deprecated. Keep exactly one call with
FD_CLOEXEC, in test_pipe_fd_cloexec().

Signed-off-by: Simon McVittie <smcv@collabora.com>
This commit is contained in:
Simon McVittie 2024-02-09 11:13:56 +00:00
parent 0701943d9f
commit 82c9a4631d

View File

@ -140,7 +140,7 @@ test_pipe_struct (void)
g_test_summary ("Test GUnixPipe structure");
res = g_unix_pipe_open (&pair, FD_CLOEXEC, &error);
res = g_unix_pipe_open (&pair, O_CLOEXEC, &error);
g_assert_no_error (error);
g_assert_true (res);
@ -199,7 +199,7 @@ test_pipe_struct_auto (void)
GError *error = NULL;
gboolean res;
res = g_unix_pipe_open (&pair, FD_CLOEXEC, &error);
res = g_unix_pipe_open (&pair, O_CLOEXEC, &error);
g_assert_no_error (error);
g_assert_true (res);