diff --git a/gio/tests/converter-stream.c b/gio/tests/converter-stream.c index 6befa274c..8c4731590 100644 --- a/gio/tests/converter-stream.c +++ b/gio/tests/converter-stream.c @@ -1022,10 +1022,10 @@ test_converter_pollable (void) } /* Wait a few ticks to check for the pipe to propagate the - * write. Finesses the race condition in the following test, - * where is_readable fails because the write hasn't propagated, - * but the read then succeeds because it has. */ - g_usleep (80L); + * write. We can’t wait on a GSource as that might affect the stream under + * test, so just poll. */ + while (!g_pollable_input_stream_is_readable (pollable_in)) + g_usleep (80L); is_readable = g_pollable_input_stream_is_readable (pollable_in); res = g_pollable_input_stream_read_nonblocking (pollable_in,