mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-09-27 17:52:58 +02:00
tests: port from g_test_trap_subprocess() to g_test_trap_fork()
(or, in a few cases, to g_test_expect_message()) https://bugzilla.gnome.org/show_bug.cgi?id=679683
This commit is contained in:
committed by
Matthias Clasen
parent
e3a29184d5
commit
ea06ec8063
@@ -137,7 +137,7 @@ test_non_socket (void)
|
||||
pid_t first_child;
|
||||
GVariant *ret;
|
||||
const gchar *str;
|
||||
gboolean ok;
|
||||
gboolean ok, in_child;
|
||||
|
||||
error = NULL;
|
||||
|
||||
@@ -219,7 +219,12 @@ test_non_socket (void)
|
||||
break;
|
||||
}
|
||||
|
||||
if (!g_test_trap_fork (0, 0))
|
||||
/* This is #ifdef G_OS_UNIX anyway, so just use g_test_trap_fork() */
|
||||
G_GNUC_BEGIN_IGNORE_DEPRECATIONS;
|
||||
in_child = g_test_trap_fork (0, 0);
|
||||
G_GNUC_END_IGNORE_DEPRECATIONS;
|
||||
|
||||
if (!in_child)
|
||||
{
|
||||
/* parent */
|
||||
g_object_unref (streams[0]);
|
||||
|
Reference in New Issue
Block a user