Commit b222b1bf authored by Philip Withnall's avatar Philip Withnall Committed by Olivier Crête

tests: Remove redundant GLIB_CHECK_VERSION checks

Since we define GLIB_VERSION_MIN_REQUIRED, GLib will not emit deprecated
function call warnings for functions like g_type_init() or
g_thread_init().
parent 7a05b330
......@@ -55,9 +55,7 @@ main (void)
#endif
nice_address_init (&addr);
g_type_init ();
#if !GLIB_CHECK_VERSION(2,31,8)
g_thread_init (NULL);
#endif
if (!nice_address_set_from_string (&addr, "127.0.0.1"))
g_assert_not_reached ();
......
......@@ -469,12 +469,8 @@ main (void)
WSAStartup (0x0202, &w);
#endif
nice_address_init (&addr);
#if !GLIB_CHECK_VERSION(2, 36, 0)
g_type_init ();
#endif
#if !GLIB_CHECK_VERSION(2, 31, 8)
g_thread_init (NULL);
#endif
g_assert (nice_address_set_from_string (&addr, "127.0.0.1"));
......
......@@ -206,9 +206,7 @@ int main (void)
#endif
g_type_init ();
#if !GLIB_CHECK_VERSION(2,31,8)
g_thread_init (NULL);
#endif
global_mainloop = g_main_loop_new (NULL, FALSE);
......
......@@ -492,9 +492,7 @@ int main (void)
WSAStartup(0x0202, &w);
#endif
g_type_init ();
#if !GLIB_CHECK_VERSION(2,31,8)
g_thread_init (NULL);
#endif
global_mainloop = g_main_loop_new (NULL, FALSE);
......
......@@ -809,9 +809,7 @@ int main (void)
WSAStartup(0x0202, &w);
#endif
g_type_init ();
#if !GLIB_CHECK_VERSION(2,31,8)
g_thread_init(NULL);
#endif
global_mainloop = g_main_loop_new (NULL, FALSE);
......
......@@ -111,12 +111,8 @@ int main (void)
WSADATA w;
WSAStartup (0x0202, &w);
#endif
#if !GLIB_CHECK_VERSION(2, 36, 0)
g_type_init ();
#endif
#if !GLIB_CHECK_VERSION(2, 31, 8)
g_thread_init (NULL);
#endif
l_data = g_malloc0 (sizeof (CancellationData));
l_data->cancellable = g_cancellable_new ();
......
......@@ -153,12 +153,8 @@ int main (void)
WSADATA w;
WSAStartup (0x0202, &w);
#endif
#if !GLIB_CHECK_VERSION(2, 36, 0)
g_type_init ();
#endif
#if !GLIB_CHECK_VERSION(2, 31, 8)
g_thread_init (NULL);
#endif
l_data = g_malloc0 (sizeof (ClosingData));
r_data = g_malloc0 (sizeof (ClosingData));
......
......@@ -158,12 +158,8 @@ int main (void)
WSADATA w;
WSAStartup (0x0202, &w);
#endif
#if !GLIB_CHECK_VERSION(2, 36, 0)
g_type_init ();
#endif
#if !GLIB_CHECK_VERSION(2,31,8)
g_thread_init (NULL);
#endif
l_data = g_malloc0 (sizeof (ThreadData));
r_data = g_malloc0 (sizeof (ThreadData));
......
......@@ -124,12 +124,8 @@ int main (void)
WSADATA w;
WSAStartup (0x0202, &w);
#endif
#if !GLIB_CHECK_VERSION(2, 36, 0)
g_type_init ();
#endif
#if !GLIB_CHECK_VERSION(2,31,8)
g_thread_init (NULL);
#endif
l_data = g_malloc0 (sizeof (ThreadData));
r_data = g_malloc0 (sizeof (ThreadData));
......
......@@ -73,9 +73,7 @@ main (void)
nice_address_init (&addr);
g_type_init ();
#if !GLIB_CHECK_VERSION(2,31,8)
g_thread_init(NULL);
#endif
loop = g_main_loop_new (NULL, FALSE);
......
......@@ -402,9 +402,7 @@ int main (void)
WSAStartup(0x0202, &w);
#endif
g_type_init ();
#if !GLIB_CHECK_VERSION(2,31,8)
g_thread_init(NULL);
#endif
global_mainloop = g_main_loop_new (NULL, FALSE);
......
......@@ -808,12 +808,8 @@ main (int argc, char *argv[])
WSADATA w;
WSAStartup (0x0202, &w);
#endif
#if !GLIB_CHECK_VERSION(2, 36, 0)
g_type_init ();
#endif
#if !GLIB_CHECK_VERSION(2, 31, 8)
g_thread_init (NULL);
#endif
if (!long_mode) {
/* Quick mode. Just test each of the stream APIs in reliable and
......
......@@ -197,9 +197,7 @@ int main (void)
WSAStartup(0x0202, &w);
#endif
g_type_init ();
#if !GLIB_CHECK_VERSION(2,31,8)
g_thread_init(NULL);
#endif
lmainctx = g_main_context_new ();
rmainctx = g_main_context_new ();
......
......@@ -62,9 +62,7 @@ main (void)
nice_address_init (&addr_remote);
g_type_init ();
#if !GLIB_CHECK_VERSION(2,31,8)
g_thread_init(NULL);
#endif
g_assert (nice_address_set_from_string (&addr_local, "127.0.0.1"));
g_assert (nice_address_set_from_string (&addr_remote, "127.0.0.1"));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment