mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-08-20 15:48:54 +02:00
Merge branch 'fix-protocol-test-win32' into 'master'
Use win32 io channel on windows for the protocol test See merge request GNOME/glib!613
This commit is contained in:
@@ -162,7 +162,11 @@ test_message (void)
|
|||||||
tlb = g_test_log_buffer_new ();
|
tlb = g_test_log_buffer_new ();
|
||||||
loop = g_main_loop_new (NULL, FALSE);
|
loop = g_main_loop_new (NULL, FALSE);
|
||||||
|
|
||||||
|
#ifdef G_OS_WIN32
|
||||||
|
channel = g_io_channel_win32_new_fd (pipes[0]);
|
||||||
|
#else
|
||||||
channel = g_io_channel_unix_new (pipes[0]);
|
channel = g_io_channel_unix_new (pipes[0]);
|
||||||
|
#endif
|
||||||
g_io_channel_set_close_on_unref (channel, TRUE);
|
g_io_channel_set_close_on_unref (channel, TRUE);
|
||||||
g_io_channel_set_encoding (channel, NULL, NULL);
|
g_io_channel_set_encoding (channel, NULL, NULL);
|
||||||
g_io_channel_set_buffered (channel, FALSE);
|
g_io_channel_set_buffered (channel, FALSE);
|
||||||
@@ -285,7 +289,11 @@ test_error (void)
|
|||||||
tlb = g_test_log_buffer_new ();
|
tlb = g_test_log_buffer_new ();
|
||||||
loop = g_main_loop_new (NULL, FALSE);
|
loop = g_main_loop_new (NULL, FALSE);
|
||||||
|
|
||||||
|
#ifdef G_OS_WIN32
|
||||||
|
channel = g_io_channel_win32_new_fd (pipes[0]);
|
||||||
|
#else
|
||||||
channel = g_io_channel_unix_new (pipes[0]);
|
channel = g_io_channel_unix_new (pipes[0]);
|
||||||
|
#endif
|
||||||
g_io_channel_set_close_on_unref (channel, TRUE);
|
g_io_channel_set_close_on_unref (channel, TRUE);
|
||||||
g_io_channel_set_encoding (channel, NULL, NULL);
|
g_io_channel_set_encoding (channel, NULL, NULL);
|
||||||
g_io_channel_set_buffered (channel, FALSE);
|
g_io_channel_set_buffered (channel, FALSE);
|
||||||
|
Reference in New Issue
Block a user