From c173c0beb4e0f664faf616bd6475b6c5c1aa50fb Mon Sep 17 00:00:00 2001 From: Matthias Clasen Date: Mon, 2 Apr 2012 07:59:23 -0400 Subject: [PATCH] Drop g_thread_init from tests This is not needed anymore. --- tests/refcount/Makefile.am | 3 +-- tests/refcount/closures.c | 1 - tests/refcount/objects.c | 1 - tests/refcount/objects2.c | 3 +-- tests/refcount/properties.c | 1 - tests/refcount/properties2.c | 1 - tests/refcount/properties3.c | 2 -- tests/refcount/signals.c | 4 ---- 8 files changed, 2 insertions(+), 14 deletions(-) diff --git a/tests/refcount/Makefile.am b/tests/refcount/Makefile.am index 1c7d71648..49a5dc28f 100644 --- a/tests/refcount/Makefile.am +++ b/tests/refcount/Makefile.am @@ -6,11 +6,10 @@ INCLUDES = \ $(GLIB_DEBUG_FLAGS) libglib = $(top_builddir)/glib/libglib-2.0.la -libgthread = $(top_builddir)/gthread/libgthread-2.0.la libgmodule = $(top_builddir)/gmodule/libgmodule-2.0.la libgobject = $(top_builddir)/gobject/libgobject-2.0.la -LDADD = $(libglib) $(libgobject) $(libgthread) $(G_THREAD_LIBS) +LDADD = $(libglib) $(libgobject) test_programs = \ closures \ diff --git a/tests/refcount/closures.c b/tests/refcount/closures.c index 5bd20a042..d0a64f0ce 100644 --- a/tests/refcount/closures.c +++ b/tests/refcount/closures.c @@ -241,7 +241,6 @@ main (int argc, GTest *object; guint i; - g_thread_init (NULL); g_print ("START: %s\n", argv[0]); g_log_set_always_fatal (G_LOG_LEVEL_WARNING | G_LOG_LEVEL_CRITICAL | g_log_set_always_fatal (G_LOG_FATAL_MASK)); g_type_init (); diff --git a/tests/refcount/objects.c b/tests/refcount/objects.c index 1c40c6474..230a16001 100644 --- a/tests/refcount/objects.c +++ b/tests/refcount/objects.c @@ -117,7 +117,6 @@ main (int argc, char **argv) GArray *test_threads; const guint n_threads = 5; - g_thread_init (NULL); g_print ("START: %s\n", argv[0]); g_log_set_always_fatal (G_LOG_LEVEL_WARNING | G_LOG_LEVEL_CRITICAL | g_log_set_always_fatal (G_LOG_FATAL_MASK)); g_type_init (); diff --git a/tests/refcount/objects2.c b/tests/refcount/objects2.c index b57863d4b..66a076bbc 100644 --- a/tests/refcount/objects2.c +++ b/tests/refcount/objects2.c @@ -101,7 +101,6 @@ main (int argc, char **argv) gint i; GTest *test; - g_thread_init (NULL); g_print ("START: %s\n", argv[0]); g_log_set_always_fatal (G_LOG_LEVEL_WARNING | G_LOG_LEVEL_CRITICAL | g_log_set_always_fatal (G_LOG_FATAL_MASK)); g_type_init (); @@ -113,6 +112,6 @@ main (int argc, char **argv) } g_print ("\n"); - + return 0; } diff --git a/tests/refcount/properties.c b/tests/refcount/properties.c index a69e3ecc3..f7c29280a 100644 --- a/tests/refcount/properties.c +++ b/tests/refcount/properties.c @@ -194,7 +194,6 @@ main (int argc, char **argv) GArray *test_threads; const gint n_threads = 5; - g_thread_init (NULL); g_print ("START: %s\n", argv[0]); g_log_set_always_fatal (G_LOG_LEVEL_WARNING | G_LOG_LEVEL_CRITICAL | g_log_set_always_fatal (G_LOG_FATAL_MASK)); g_type_init (); diff --git a/tests/refcount/properties2.c b/tests/refcount/properties2.c index 90ea42bf5..3bef8e54a 100644 --- a/tests/refcount/properties2.c +++ b/tests/refcount/properties2.c @@ -178,7 +178,6 @@ main (int argc, char **argv) gint i; GTest *test; - g_thread_init (NULL); g_print ("START: %s\n", argv[0]); g_log_set_always_fatal (G_LOG_LEVEL_WARNING | G_LOG_LEVEL_CRITICAL | g_log_set_always_fatal (G_LOG_FATAL_MASK)); g_type_init (); diff --git a/tests/refcount/properties3.c b/tests/refcount/properties3.c index 56661d655..66f68b5bc 100644 --- a/tests/refcount/properties3.c +++ b/tests/refcount/properties3.c @@ -159,8 +159,6 @@ main (int argc, char **argv) GArray *test_threads; const gint n_threads = 5; - g_thread_init (NULL); - g_print ("START: %s\n", argv[0]); g_log_set_always_fatal (G_LOG_LEVEL_WARNING | G_LOG_LEVEL_CRITICAL | g_log_set_always_fatal (G_LOG_FATAL_MASK)); g_type_init (); diff --git a/tests/refcount/signals.c b/tests/refcount/signals.c index 90bae419b..b8b4c45a1 100644 --- a/tests/refcount/signals.c +++ b/tests/refcount/signals.c @@ -98,9 +98,6 @@ my_test_class_init (GTestClass * klass) parent_class = g_type_class_ref (G_TYPE_OBJECT); - if (!g_thread_supported ()) - g_thread_init (NULL); - gobject_class->dispose = my_test_dispose; gobject_class->set_property = my_test_set_property; gobject_class->get_property = my_test_get_property; @@ -239,7 +236,6 @@ main (int argc, char **argv) GArray *test_threads; const gint n_threads = 1; - g_thread_init (NULL); g_print ("START: %s\n", argv[0]); g_log_set_always_fatal (G_LOG_LEVEL_WARNING | G_LOG_LEVEL_CRITICAL | g_log_set_always_fatal (G_LOG_FATAL_MASK)); g_type_init ();