mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2024-11-11 11:56:16 +01:00
Merge branch '2322-fflush-test-dbus' into 'master'
gtestdbus: Flush stdout and stderr before forking a monitor process Closes #2322 See merge request GNOME/glib!1950
This commit is contained in:
commit
985bb56996
@ -251,6 +251,16 @@ watcher_init (void)
|
|||||||
g_assert_not_reached ();
|
g_assert_not_reached ();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* flush streams to avoid buffers being duplicated in the child and
|
||||||
|
* flushed by both the child and parent later
|
||||||
|
*
|
||||||
|
* FIXME: This is a workaround for the fact that watch_parent() uses
|
||||||
|
* non-async-signal-safe API. See
|
||||||
|
* https://gitlab.gnome.org/GNOME/glib/-/issues/2322#note_1034330
|
||||||
|
*/
|
||||||
|
fflush (stdout);
|
||||||
|
fflush (stderr);
|
||||||
|
|
||||||
switch (fork ())
|
switch (fork ())
|
||||||
{
|
{
|
||||||
case -1:
|
case -1:
|
||||||
|
Loading…
Reference in New Issue
Block a user