[Pkg-telepathy-commits] [telepathy-glib] 62/111: Stop calling g_type_init()

Simon McVittie smcv at debian.org
Wed Mar 19 18:07:26 UTC 2014


This is an automated email from the git hooks/post-receive script.

smcv pushed a commit to branch debian
in repository telepathy-glib.

commit e3d4c2977fbf086e7d42c77e3713e1bcddda2a9c
Author: Simon McVittie <simon.mcvittie at collabora.co.uk>
Date:   Mon Nov 11 17:19:59 2013 +0000

    Stop calling g_type_init()
    
    It was deprecated in GLib 2.36, and we already have a hard dependency
    on that version.
    
    Bug: https://bugs.freedesktop.org/show_bug.cgi?id=71048
    Reviewed-by: Guillaume Desmottes <guillaume.desmottes at collabora.co.uk>
---
 configure.ac                                    | 2 +-
 examples/client/approver.c                      | 1 -
 examples/client/contact-list.c                  | 1 -
 examples/client/dbus-tubes/accepter.c           | 2 --
 examples/client/dbus-tubes/offerer.c            | 2 --
 examples/client/extended-client.c               | 1 -
 examples/client/inspect-channel.c               | 1 -
 examples/client/inspect-cm.c                    | 1 -
 examples/client/inspect-connection.c            | 1 -
 examples/client/inspect-contact.c               | 1 -
 examples/client/list-connections.c              | 1 -
 examples/client/list-managers.c                 | 1 -
 examples/client/media-observer.c                | 1 -
 examples/client/stream-tubes/accepter.c         | 2 --
 examples/client/stream-tubes/offerer.c          | 2 --
 examples/client/text-handler.c                  | 1 -
 examples/cm/call/main.c                         | 4 ----
 telepathy-glib/errors.c                         | 1 -
 telepathy-glib/run.c                            | 2 --
 telepathy-glib/simple-client-factory.c          | 2 --
 tests/asv.c                                     | 2 --
 tests/capabilities.c                            | 1 -
 tests/contact-search-result.c                   | 1 -
 tests/dbus/account-manager.c                    | 1 -
 tests/dbus/account-request.c                    | 1 -
 tests/dbus/account.c                            | 1 -
 tests/dbus/call-cancellation.c                  | 1 -
 tests/dbus/call-channel.c                       | 1 -
 tests/dbus/channel-dispatch-operation.c         | 1 -
 tests/dbus/channel-dispatcher.c                 | 1 -
 tests/dbus/channel-introspect.c                 | 1 -
 tests/dbus/channel-manager-request-properties.c | 1 -
 tests/dbus/channel-request.c                    | 1 -
 tests/dbus/cli-group.c                          | 1 -
 tests/dbus/client.c                             | 1 -
 tests/dbus/cm-message.c                         | 1 -
 tests/dbus/cm.c                                 | 1 -
 tests/dbus/connection-aliasing.c                | 3 ---
 tests/dbus/connection-balance.c                 | 3 ---
 tests/dbus/connection-bug-18845.c               | 1 -
 tests/dbus/connection-error.c                   | 2 --
 tests/dbus/connection-getinterfaces-failure.c   | 1 -
 tests/dbus/connection-handles.c                 | 1 -
 tests/dbus/connection-inject-bug16307.c         | 1 -
 tests/dbus/connection-interests.c               | 1 -
 tests/dbus/connection.c                         | 1 -
 tests/dbus/contact-lists.c                      | 2 --
 tests/dbus/contacts-bug-19101.c                 | 1 -
 tests/dbus/contacts-mixin.c                     | 1 -
 tests/dbus/disconnection.c                      | 1 -
 tests/dbus/example-no-protocols.c               | 1 -
 tests/dbus/file-transfer-channel.c              | 1 -
 tests/dbus/finalized-in-invalidated-handler.c   | 1 -
 tests/dbus/group-mixin.c                        | 1 -
 tests/dbus/handle-repo.c                        | 1 -
 tests/dbus/handle-set.c                         | 1 -
 tests/dbus/invalidated-while-invoking-signals.c | 1 -
 tests/dbus/long-connection-name.c               | 1 -
 tests/dbus/message-mixin.c                      | 1 -
 tests/dbus/params-cm.c                          | 1 -
 tests/dbus/protocol-objects.c                   | 1 -
 tests/dbus/self-presence.c                      | 1 -
 tests/dbus/text-mixin.c                         | 1 -
 tests/dbus/text-respawn.c                       | 1 -
 tests/dbus/unsupported-interface.c              | 1 -
 tests/debug-domain.c                            | 2 --
 tests/dtmf-player.c                             | 2 --
 tests/enums.c                                   | 4 ----
 tests/gnio-util.c                               | 1 -
 tests/intset.c                                  | 2 --
 tests/lib/util.c                                | 3 ---
 tests/signal-connect-object.c                   | 1 -
 tests/util-cxx.cpp                              | 2 --
 tests/util.c                                    | 2 --
 tools/glib-errors-check-gen.py                  | 1 -
 75 files changed, 1 insertion(+), 101 deletions(-)

diff --git a/configure.ac b/configure.ac
index 2b29ff7..c1ea449 100644
--- a/configure.ac
+++ b/configure.ac
@@ -296,7 +296,7 @@ CXXFLAGS="$GLIB_CFLAGS"
 AC_LINK_IFELSE(
   [AC_LANG_PROGRAM(
      [[#include <gio/gio.h>]],
-     [[g_type_init (); g_object_unref (g_file_new_for_path ("/"));]])
+     [[g_object_unref (g_file_new_for_path ("/"));]])
   ],
   [tp_cxx_works=yes],
   [tp_cxx_works=no])
diff --git a/examples/client/approver.c b/examples/client/approver.c
index 800f197..3cc6f88 100644
--- a/examples/client/approver.c
+++ b/examples/client/approver.c
@@ -143,7 +143,6 @@ main (int argc,
   GError *error = NULL;
   TpBaseClient *approver;
 
-  g_type_init ();
   tp_debug_set_flags (g_getenv ("EXAMPLE_DEBUG"));
 
   manager = tp_account_manager_dup ();
diff --git a/examples/client/contact-list.c b/examples/client/contact-list.c
index 5ed82a4..7506d47 100644
--- a/examples/client/contact-list.c
+++ b/examples/client/contact-list.c
@@ -74,7 +74,6 @@ main (int argc,
   TpSimpleClientFactory *factory;
   GMainLoop *loop;
 
-  g_type_init ();
   tp_debug_set_flags (g_getenv ("EXAMPLE_DEBUG"));
 
   loop = g_main_loop_new (NULL, FALSE);
diff --git a/examples/client/dbus-tubes/accepter.c b/examples/client/dbus-tubes/accepter.c
index 2f2dae5..1219e6e 100644
--- a/examples/client/dbus-tubes/accepter.c
+++ b/examples/client/dbus-tubes/accepter.c
@@ -185,8 +185,6 @@ main (int argc,
   TpBaseClient *handler;
   GError *error = NULL;
 
-  g_type_init ();
-
   manager = tp_account_manager_dup ();
   handler = tp_simple_handler_new_with_am (manager, FALSE, FALSE,
       "ExampleServiceHandler", FALSE, handle_channels, NULL, NULL);
diff --git a/examples/client/dbus-tubes/offerer.c b/examples/client/dbus-tubes/offerer.c
index 2e4807b..48221a0 100644
--- a/examples/client/dbus-tubes/offerer.c
+++ b/examples/client/dbus-tubes/offerer.c
@@ -188,8 +188,6 @@ main (int argc,
   TpAccountChannelRequest *req;
   GHashTable *request;
 
-  g_type_init ();
-
   if (argc != 3)
     {
       g_printerr ("Usage: offerer gabble/jabber/ladygaga t-pain at example.com\n");
diff --git a/examples/client/extended-client.c b/examples/client/extended-client.c
index 1172231..a2af571 100644
--- a/examples/client/extended-client.c
+++ b/examples/client/extended-client.c
@@ -284,7 +284,6 @@ main (int argc,
   GError *error = NULL;
   TpDBusDaemon *dbus = NULL;
 
-  g_type_init ();
   tp_debug_set_flags (g_getenv ("EXAMPLE_DEBUG"));
 
   example_cli_init ();
diff --git a/examples/client/inspect-channel.c b/examples/client/inspect-channel.c
index 969a4f8..ef8c892 100644
--- a/examples/client/inspect-channel.c
+++ b/examples/client/inspect-channel.c
@@ -136,7 +136,6 @@ main (int argc,
   TpConnection *connection = NULL;
   GError *error = NULL;
 
-  g_type_init ();
   tp_debug_set_flags (g_getenv ("EXAMPLE_DEBUG"));
 
   if (argc < 3)
diff --git a/examples/client/inspect-cm.c b/examples/client/inspect-cm.c
index 68fefed..c2a1532 100644
--- a/examples/client/inspect-cm.c
+++ b/examples/client/inspect-cm.c
@@ -233,7 +233,6 @@ main (int argc,
   TpDBusDaemon *dbus = NULL;
   int ret = 1;
 
-  g_type_init ();
   tp_debug_set_flags (g_getenv ("EXAMPLE_DEBUG"));
 
   if (g_getenv ("EXAMPLE_TIMING") != NULL)
diff --git a/examples/client/inspect-connection.c b/examples/client/inspect-connection.c
index 6b6fa81..460887a 100644
--- a/examples/client/inspect-connection.c
+++ b/examples/client/inspect-connection.c
@@ -86,7 +86,6 @@ main (int argc,
   TpSimpleClientFactory *factory;
   GError *error = NULL;
 
-  g_type_init ();
   tp_debug_set_flags (g_getenv ("EXAMPLE_DEBUG"));
 
   if (argc < 2)
diff --git a/examples/client/inspect-contact.c b/examples/client/inspect-contact.c
index 5c967c5..f960e08 100644
--- a/examples/client/inspect-contact.c
+++ b/examples/client/inspect-contact.c
@@ -157,7 +157,6 @@ main (int argc,
   TpSimpleClientFactory *factory;
   GError *error = NULL;
 
-  g_type_init ();
   tp_debug_set_flags (g_getenv ("EXAMPLE_DEBUG"));
 
   if (argc < 2)
diff --git a/examples/client/list-connections.c b/examples/client/list-connections.c
index 1b3211f..3df69ee 100644
--- a/examples/client/list-connections.c
+++ b/examples/client/list-connections.c
@@ -62,7 +62,6 @@ main (int argc,
   TpDBusDaemon *bus_daemon;
   GError *error = NULL;
 
-  g_type_init ();
   tp_debug_set_flags (g_getenv ("EXAMPLE_DEBUG"));
 
   bus_daemon = tp_dbus_daemon_dup (&error);
diff --git a/examples/client/list-managers.c b/examples/client/list-managers.c
index bffd19b..87109e5 100644
--- a/examples/client/list-managers.c
+++ b/examples/client/list-managers.c
@@ -60,7 +60,6 @@ main (int argc,
   TpDBusDaemon *bus_daemon;
   GError *error = NULL;
 
-  g_type_init ();
   tp_debug_set_flags (g_getenv ("EXAMPLE_DEBUG"));
 
   bus_daemon = tp_dbus_daemon_dup (&error);
diff --git a/examples/client/media-observer.c b/examples/client/media-observer.c
index 0d9a694..ef0aa89 100644
--- a/examples/client/media-observer.c
+++ b/examples/client/media-observer.c
@@ -76,7 +76,6 @@ main (int argc,
   GError *error = NULL;
   TpBaseClient *observer;
 
-  g_type_init ();
   tp_debug_set_flags (g_getenv ("EXAMPLE_DEBUG"));
 
   manager = tp_account_manager_dup ();
diff --git a/examples/client/stream-tubes/accepter.c b/examples/client/stream-tubes/accepter.c
index 574173a..ed82056 100644
--- a/examples/client/stream-tubes/accepter.c
+++ b/examples/client/stream-tubes/accepter.c
@@ -135,8 +135,6 @@ main (int argc,
   TpBaseClient *handler;
   GError *error = NULL;
 
-  g_type_init ();
-
   manager = tp_account_manager_dup ();
   handler = tp_simple_handler_new_with_am (manager, FALSE, FALSE,
       "ExampleServiceHandler", FALSE, _handle_channels, NULL, NULL);
diff --git a/examples/client/stream-tubes/offerer.c b/examples/client/stream-tubes/offerer.c
index 8d62da3..16bb927 100644
--- a/examples/client/stream-tubes/offerer.c
+++ b/examples/client/stream-tubes/offerer.c
@@ -146,8 +146,6 @@ main (int argc,
       return 2;
     }
 
-  g_type_init ();
-
   factory = TP_SIMPLE_CLIENT_FACTORY (tp_automatic_client_factory_new (NULL));
 
   account_path = g_strconcat (TP_ACCOUNT_OBJECT_PATH_BASE, argv[1], NULL);
diff --git a/examples/client/text-handler.c b/examples/client/text-handler.c
index 4eb94f5..6a079c8 100644
--- a/examples/client/text-handler.c
+++ b/examples/client/text-handler.c
@@ -124,7 +124,6 @@ main (int argc,
   GError *error = NULL;
   TpBaseClient *handler;
 
-  g_type_init ();
   tp_debug_set_flags (g_getenv ("EXAMPLE_DEBUG"));
 
   manager = tp_account_manager_dup ();
diff --git a/examples/cm/call/main.c b/examples/cm/call/main.c
index aee9f17..1c5c966 100644
--- a/examples/cm/call/main.c
+++ b/examples/cm/call/main.c
@@ -50,10 +50,6 @@ main (int argc,
     tp_debug_set_persistent (TRUE);
 #endif
 
-  /* strictly speaking, this is only necessary for client code, but it's
-   * harmless here */
-  g_type_init ();
-
   return tp_run_connection_manager ("telepathy-example-cm-call",
       VERSION, construct_cm, argc, argv);
 }
diff --git a/telepathy-glib/errors.c b/telepathy-glib/errors.c
index bc045b5..358f313 100644
--- a/telepathy-glib/errors.c
+++ b/telepathy-glib/errors.c
@@ -335,7 +335,6 @@ tp_error_quark (void)
        * "tp-error-quark" */
       GQuark domain = g_quark_from_static_string ("tp_errors");
 
-      g_type_init ();
       dbus_g_error_domain_register (domain, TP_ERROR_PREFIX,
           TP_TYPE_ERROR);
       g_once_init_leave (&quark, domain);
diff --git a/telepathy-glib/run.c b/telepathy-glib/run.c
index c3df190..1b3393c 100644
--- a/telepathy-glib/run.c
+++ b/telepathy-glib/run.c
@@ -219,8 +219,6 @@ tp_run_connection_manager (const char *prog_name,
 
   add_signal_handlers ();
 
-  g_type_init ();
-
   g_set_prgname (prog_name);
 
 #ifdef ENABLE_BACKTRACE
diff --git a/telepathy-glib/simple-client-factory.c b/telepathy-glib/simple-client-factory.c
index c096ea0..0060b9d 100644
--- a/telepathy-glib/simple-client-factory.c
+++ b/telepathy-glib/simple-client-factory.c
@@ -51,8 +51,6 @@
  *   TpSimpleClientFactory *factory;
  *   TpAccountManager *manager;
  *
- *   g_type_init ();
- *
  *   factory = my_factory_new ();
  *   manager = tp_account_manager_new_with_factory (factory);
  *   tp_account_manager_set_default (manager);
diff --git a/tests/asv.c b/tests/asv.c
index 80981ff..390304f 100644
--- a/tests/asv.c
+++ b/tests/asv.c
@@ -37,8 +37,6 @@ int main (int argc, char **argv)
 
   /* Setup */
 
-  g_type_init ();
-
   hash = tp_asv_new (
       "d:123.2", G_TYPE_DOUBLE, 123.2,
       "s:test", G_TYPE_STRING, "test",
diff --git a/tests/capabilities.c b/tests/capabilities.c
index 7eab5e7..3427117 100644
--- a/tests/capabilities.c
+++ b/tests/capabilities.c
@@ -23,7 +23,6 @@ static void
 setup (Test *test,
     gconstpointer data)
 {
-  g_type_init ();
   tp_debug_set_flags ("all");
 }
 
diff --git a/tests/contact-search-result.c b/tests/contact-search-result.c
index 63f914b..185a31c 100644
--- a/tests/contact-search-result.c
+++ b/tests/contact-search-result.c
@@ -63,7 +63,6 @@ int
 main (int argc,
     char **argv)
 {
-  g_type_init ();
   tp_debug_set_flags ("all");
 
   g_test_init (&argc, &argv, NULL);
diff --git a/tests/dbus/account-manager.c b/tests/dbus/account-manager.c
index 65b210d..0cf95e9 100644
--- a/tests/dbus/account-manager.c
+++ b/tests/dbus/account-manager.c
@@ -134,7 +134,6 @@ static void
 setup (Test *test,
     gconstpointer data)
 {
-  g_type_init ();
   tp_debug_set_flags ("all");
 
   test->mainloop = g_main_loop_new (NULL, FALSE);
diff --git a/tests/dbus/account-request.c b/tests/dbus/account-request.c
index 055be2e..aedc6b8 100644
--- a/tests/dbus/account-request.c
+++ b/tests/dbus/account-request.c
@@ -547,7 +547,6 @@ int
 main (int argc,
     char **argv)
 {
-  g_type_init ();
   tp_tests_abort_after (10);
   tp_debug_set_flags ("all");
 
diff --git a/tests/dbus/account.c b/tests/dbus/account.c
index 81ac8f1..1df043a 100644
--- a/tests/dbus/account.c
+++ b/tests/dbus/account.c
@@ -930,7 +930,6 @@ int
 main (int argc,
       char **argv)
 {
-  g_type_init ();
   tp_tests_abort_after (10);
   tp_debug_set_flags ("all");
 
diff --git a/tests/dbus/call-cancellation.c b/tests/dbus/call-cancellation.c
index d1f15f8..95e790f 100644
--- a/tests/dbus/call-cancellation.c
+++ b/tests/dbus/call-cancellation.c
@@ -174,7 +174,6 @@ main (int argc,
   TpProxyPendingCall *pc;
   gpointer tmp_obj;
 
-  g_type_init ();
   tp_tests_abort_after (10);
   tp_debug_set_flags ("all");
 
diff --git a/tests/dbus/call-channel.c b/tests/dbus/call-channel.c
index 810c0f4..12bafce 100644
--- a/tests/dbus/call-channel.c
+++ b/tests/dbus/call-channel.c
@@ -71,7 +71,6 @@ setup (Test *test,
   guint not_a_media_type = 31337;
   GQuark conn_features[] = { TP_CONNECTION_FEATURE_CONNECTED, 0 };
 
-  g_type_init ();
   tp_debug_set_flags ("all");
 
   test->mainloop = g_main_loop_new (NULL, FALSE);
diff --git a/tests/dbus/channel-dispatch-operation.c b/tests/dbus/channel-dispatch-operation.c
index 90406cf..f5c39f2 100644
--- a/tests/dbus/channel-dispatch-operation.c
+++ b/tests/dbus/channel-dispatch-operation.c
@@ -55,7 +55,6 @@ setup (Test *test,
 {
   DBusConnection *libdbus;
 
-  g_type_init ();
   tp_debug_set_flags ("all");
 
   test->mainloop = g_main_loop_new (NULL, FALSE);
diff --git a/tests/dbus/channel-dispatcher.c b/tests/dbus/channel-dispatcher.c
index b789226..d3b466e 100644
--- a/tests/dbus/channel-dispatcher.c
+++ b/tests/dbus/channel-dispatcher.c
@@ -27,7 +27,6 @@ static void
 setup (Test *test,
        gconstpointer data)
 {
-  g_type_init ();
   tp_debug_set_flags ("all");
 
   test->mainloop = g_main_loop_new (NULL, FALSE);
diff --git a/tests/dbus/channel-introspect.c b/tests/dbus/channel-introspect.c
index 072cf69..989dfde 100644
--- a/tests/dbus/channel-introspect.c
+++ b/tests/dbus/channel-introspect.c
@@ -137,7 +137,6 @@ main (int argc,
   GQuark some_features[] = { TP_CHANNEL_FEATURE_CORE,
       TP_CHANNEL_FEATURE_CHAT_STATES, 0 };
 
-  g_type_init ();
   tp_tests_abort_after (10);
   dbus = tp_tests_dbus_daemon_dup_or_die ();
 
diff --git a/tests/dbus/channel-manager-request-properties.c b/tests/dbus/channel-manager-request-properties.c
index 69aaa39..71ce770 100644
--- a/tests/dbus/channel-manager-request-properties.c
+++ b/tests/dbus/channel-manager-request-properties.c
@@ -42,7 +42,6 @@ setup (Test *test,
   gboolean ok;
   gchar *name, *conn_path;
 
-  g_type_init ();
   tp_debug_set_flags ("all");
 
   test->mainloop = g_main_loop_new (NULL, FALSE);
diff --git a/tests/dbus/channel-request.c b/tests/dbus/channel-request.c
index 7cb7ca0..1392019 100644
--- a/tests/dbus/channel-request.c
+++ b/tests/dbus/channel-request.c
@@ -75,7 +75,6 @@ setup (Test *test,
 {
   DBusConnection *libdbus;
 
-  g_type_init ();
   tp_debug_set_flags ("all");
 
   test->mainloop = g_main_loop_new (NULL, FALSE);
diff --git a/tests/dbus/cli-group.c b/tests/dbus/cli-group.c
index 82a138d..59c007c 100644
--- a/tests/dbus/cli-group.c
+++ b/tests/dbus/cli-group.c
@@ -496,7 +496,6 @@ main (int argc,
   gchar *name;
 
   tp_tests_abort_after (10);
-  g_type_init ();
   tp_debug_set_flags ("all");
   dbus = tp_tests_dbus_daemon_dup_or_die ();
 
diff --git a/tests/dbus/client.c b/tests/dbus/client.c
index 9146f4f..3f442b8 100644
--- a/tests/dbus/client.c
+++ b/tests/dbus/client.c
@@ -27,7 +27,6 @@ static void
 setup (Test *test,
        gconstpointer data)
 {
-  g_type_init ();
   tp_debug_set_flags ("all");
 
   test->mainloop = g_main_loop_new (NULL, FALSE);
diff --git a/tests/dbus/cm-message.c b/tests/dbus/cm-message.c
index 2c0f56d..3084d53 100644
--- a/tests/dbus/cm-message.c
+++ b/tests/dbus/cm-message.c
@@ -22,7 +22,6 @@ static void
 setup (Test *test,
     gconstpointer data)
 {
-  g_type_init ();
   tp_debug_set_flags ("all");
 
   tp_tests_create_and_connect_conn (TP_TESTS_TYPE_SIMPLE_CONNECTION,
diff --git a/tests/dbus/cm.c b/tests/dbus/cm.c
index 3888277..ad42854 100644
--- a/tests/dbus/cm.c
+++ b/tests/dbus/cm.c
@@ -131,7 +131,6 @@ setup (Test *test,
   TpBaseConnectionManager *service_cm_as_base;
   gboolean ok;
 
-  g_type_init ();
   tp_debug_set_flags ("all");
 
   test->mainloop = g_main_loop_new (NULL, FALSE);
diff --git a/tests/dbus/connection-aliasing.c b/tests/dbus/connection-aliasing.c
index ddadab8..2572dc8 100644
--- a/tests/dbus/connection-aliasing.c
+++ b/tests/dbus/connection-aliasing.c
@@ -48,7 +48,6 @@ setup (Test *test,
   GError *error = NULL;
   GQuark features[] = { TP_CONNECTION_FEATURE_CONNECTED, 0 };
 
-  g_type_init ();
   tp_debug_set_flags ("all");
   test->dbus = tp_tests_dbus_daemon_dup_or_die ();
 
@@ -153,8 +152,6 @@ int
 main (int argc,
       char **argv)
 {
-  g_type_init ();
-
   tp_tests_abort_after (5);
   g_test_init (&argc, &argv, NULL);
 
diff --git a/tests/dbus/connection-balance.c b/tests/dbus/connection-balance.c
index b247e14..c808996 100644
--- a/tests/dbus/connection-balance.c
+++ b/tests/dbus/connection-balance.c
@@ -202,7 +202,6 @@ setup (Test *test,
   GQuark features[] = { TP_CONNECTION_FEATURE_CONNECTED, 0 };
   GType conn_type = GPOINTER_TO_SIZE (data);
 
-  g_type_init ();
   tp_debug_set_flags ("all");
   test->dbus = tp_tests_dbus_daemon_dup_or_die ();
 
@@ -383,8 +382,6 @@ int
 main (int argc,
       char **argv)
 {
-  g_type_init ();
-
   tp_tests_abort_after (5);
   g_test_init (&argc, &argv, NULL);
 
diff --git a/tests/dbus/connection-bug-18845.c b/tests/dbus/connection-bug-18845.c
index 88a3081..e76e626 100644
--- a/tests/dbus/connection-bug-18845.c
+++ b/tests/dbus/connection-bug-18845.c
@@ -46,7 +46,6 @@ main (int argc,
   DBusGProxy *proxy;
 
   tp_tests_abort_after (10);
-  g_type_init ();
   invalidated_for_test.domain = TP_ERROR;
 
   tp_debug_set_flags ("all");
diff --git a/tests/dbus/connection-error.c b/tests/dbus/connection-error.c
index 3d2e561..bf8ecaf 100644
--- a/tests/dbus/connection-error.c
+++ b/tests/dbus/connection-error.c
@@ -87,7 +87,6 @@ example_com_error_quark (void)
 
       g_assert (sizeof (GQuark) <= sizeof (gsize));
 
-      g_type_init ();
       dbus_g_error_domain_register (domain, "com.example",
           example_com_error_get_type ());
       g_once_init_leave (&quark, domain);
@@ -116,7 +115,6 @@ global_setup (void)
 
   done = TRUE;
 
-  g_type_init ();
   tp_debug_set_flags ("all");
 
   tp_proxy_subclass_add_error_mapping (TP_TYPE_CONNECTION,
diff --git a/tests/dbus/connection-getinterfaces-failure.c b/tests/dbus/connection-getinterfaces-failure.c
index 4d3494a..693feef 100644
--- a/tests/dbus/connection-getinterfaces-failure.c
+++ b/tests/dbus/connection-getinterfaces-failure.c
@@ -94,7 +94,6 @@ main (int argc,
   gchar *conn_path;
 
   tp_tests_abort_after (10);
-  g_type_init ();
   tp_debug_set_flags ("all");
   mainloop = g_main_loop_new (NULL, FALSE);
   dbus = tp_tests_dbus_daemon_dup_or_die ();
diff --git a/tests/dbus/connection-handles.c b/tests/dbus/connection-handles.c
index bab685f..2324465 100644
--- a/tests/dbus/connection-handles.c
+++ b/tests/dbus/connection-handles.c
@@ -294,7 +294,6 @@ main (int argc,
   /* Setup */
 
   tp_tests_abort_after (10);
-  g_type_init ();
   tp_debug_set_flags ("all");
   dbus = tp_tests_dbus_daemon_dup_or_die ();
 
diff --git a/tests/dbus/connection-inject-bug16307.c b/tests/dbus/connection-inject-bug16307.c
index 87bd041..3796530 100644
--- a/tests/dbus/connection-inject-bug16307.c
+++ b/tests/dbus/connection-inject-bug16307.c
@@ -41,7 +41,6 @@ main (int argc,
   TpConnection *conn;
 
   tp_tests_abort_after (10);
-  g_type_init ();
   tp_debug_set_flags ("all");
   mainloop = g_main_loop_new (NULL, FALSE);
   dbus = tp_tests_dbus_daemon_dup_or_die ();
diff --git a/tests/dbus/connection-interests.c b/tests/dbus/connection-interests.c
index 7ffbda6..d5d703e 100644
--- a/tests/dbus/connection-interests.c
+++ b/tests/dbus/connection-interests.c
@@ -148,7 +148,6 @@ setup (Test *test,
   GError *error = NULL;
   GQuark features[] = { TP_CONNECTION_FEATURE_CONNECTED, 0 };
 
-  g_type_init ();
   tp_debug_set_flags ("all");
   test->dbus = tp_tests_dbus_daemon_dup_or_die ();
 
diff --git a/tests/dbus/connection.c b/tests/dbus/connection.c
index 51a8872..8ed18f6 100644
--- a/tests/dbus/connection.c
+++ b/tests/dbus/connection.c
@@ -57,7 +57,6 @@ setup (Test *test,
 
   invalidated_for_test.domain = TP_ERROR;
 
-  g_type_init ();
   tp_debug_set_flags ("all");
   test->dbus = tp_tests_dbus_daemon_dup_or_die ();
 
diff --git a/tests/dbus/contact-lists.c b/tests/dbus/contact-lists.c
index f072ef7..43ab262 100644
--- a/tests/dbus/contact-lists.c
+++ b/tests/dbus/contact-lists.c
@@ -326,7 +326,6 @@ setup_pre_connect (
   GError *error = NULL;
   const gchar *account;
 
-  g_type_init ();
   tp_debug_set_flags ("all");
   test->dbus = tp_tests_dbus_daemon_dup_or_die ();
   test->main_loop = g_main_loop_new (NULL, FALSE);
@@ -2740,7 +2739,6 @@ int
 main (int argc,
       char **argv)
 {
-  g_type_init ();
   tp_tests_abort_after (30);
   tp_debug_set_flags ("all");
 
diff --git a/tests/dbus/contacts-bug-19101.c b/tests/dbus/contacts-bug-19101.c
index 77474e1..debc35b 100644
--- a/tests/dbus/contacts-bug-19101.c
+++ b/tests/dbus/contacts-bug-19101.c
@@ -146,7 +146,6 @@ main (int argc,
   /* Setup */
 
   tp_tests_abort_after (10);
-  g_type_init ();
   tp_debug_set_flags ("all");
   dbus = tp_tests_dbus_daemon_dup_or_die ();
 
diff --git a/tests/dbus/contacts-mixin.c b/tests/dbus/contacts-mixin.c
index 5e286c3..c3146ed 100644
--- a/tests/dbus/contacts-mixin.c
+++ b/tests/dbus/contacts-mixin.c
@@ -158,7 +158,6 @@ main (int argc,
   /* Setup */
 
   tp_tests_abort_after (10);
-  g_type_init ();
   tp_debug_set_flags ("all");
   dbus = tp_tests_dbus_daemon_dup_or_die ();
 
diff --git a/tests/dbus/disconnection.c b/tests/dbus/disconnection.c
index bfa55cb..ef8ad11 100644
--- a/tests/dbus/disconnection.c
+++ b/tests/dbus/disconnection.c
@@ -164,7 +164,6 @@ main (int argc,
   gboolean freed = FALSE;
 
   tp_tests_abort_after (10);
-  g_type_init ();
   tp_debug_set_flags ("all");
 
   freed_user_data = tp_intset_sized_new (N_DAEMONS);
diff --git a/tests/dbus/example-no-protocols.c b/tests/dbus/example-no-protocols.c
index 4a076f5..2d22acd 100644
--- a/tests/dbus/example-no-protocols.c
+++ b/tests/dbus/example-no-protocols.c
@@ -97,7 +97,6 @@ main (int argc,
   gboolean saw_exited;
 
   tp_tests_abort_after (5);
-  g_type_init ();
 
   tp_debug_set_flags ("all");
 
diff --git a/tests/dbus/file-transfer-channel.c b/tests/dbus/file-transfer-channel.c
index b93ac6e..be4c4ea 100644
--- a/tests/dbus/file-transfer-channel.c
+++ b/tests/dbus/file-transfer-channel.c
@@ -585,7 +585,6 @@ main (int argc,
       char **argv)
 {
   tp_tests_abort_after (10);
-  g_type_init ();
   tp_debug_set_flags ("all");
 
   g_test_init (&argc, &argv, NULL);
diff --git a/tests/dbus/finalized-in-invalidated-handler.c b/tests/dbus/finalized-in-invalidated-handler.c
index 03f7d66..0eab579 100644
--- a/tests/dbus/finalized-in-invalidated-handler.c
+++ b/tests/dbus/finalized-in-invalidated-handler.c
@@ -84,7 +84,6 @@ main (int argc,
   TpHandle handle;
 
   tp_tests_abort_after (10);
-  g_type_init ();
   tp_debug_set_flags ("all");
   mainloop = g_main_loop_new (NULL, FALSE);
   dbus = tp_tests_dbus_daemon_dup_or_die ();
diff --git a/tests/dbus/group-mixin.c b/tests/dbus/group-mixin.c
index 0b7a0a3..8943f4b 100644
--- a/tests/dbus/group-mixin.c
+++ b/tests/dbus/group-mixin.c
@@ -526,7 +526,6 @@ main (int argc,
   gchar *chan_path;
 
   tp_tests_abort_after (10);
-  g_type_init ();
   tp_debug_set_flags ("all");
   dbus = tp_tests_dbus_daemon_dup_or_die ();
 
diff --git a/tests/dbus/handle-repo.c b/tests/dbus/handle-repo.c
index ec80024..500826f 100644
--- a/tests/dbus/handle-repo.c
+++ b/tests/dbus/handle-repo.c
@@ -101,7 +101,6 @@ test_handles (void)
 int main (int argc, char **argv)
 {
   tp_tests_abort_after (10);
-  g_type_init ();
 
   test_handles ();
 
diff --git a/tests/dbus/handle-set.c b/tests/dbus/handle-set.c
index 4dc774b..4e9f9c0 100644
--- a/tests/dbus/handle-set.c
+++ b/tests/dbus/handle-set.c
@@ -27,7 +27,6 @@ main (int argc,
   TpHandle h1, h2, h3, h4;
 
   tp_tests_abort_after (10);
-  g_type_init ();
 
   repo = tp_tests_object_new_static_class (TP_TYPE_DYNAMIC_HANDLE_REPO,
       "handle-type", TP_HANDLE_TYPE_CONTACT,
diff --git a/tests/dbus/invalidated-while-invoking-signals.c b/tests/dbus/invalidated-while-invoking-signals.c
index 9360644..01a5f30 100644
--- a/tests/dbus/invalidated-while-invoking-signals.c
+++ b/tests/dbus/invalidated-while-invoking-signals.c
@@ -65,7 +65,6 @@ main (int argc,
   gchar *path;
 
   tp_tests_abort_after (10);
-  g_type_init ();
   tp_debug_set_flags ("all");
   mainloop = g_main_loop_new (NULL, FALSE);
   dbus = tp_tests_dbus_daemon_dup_or_die ();
diff --git a/tests/dbus/long-connection-name.c b/tests/dbus/long-connection-name.c
index 8be0e20..ac2b38b 100644
--- a/tests/dbus/long-connection-name.c
+++ b/tests/dbus/long-connection-name.c
@@ -43,7 +43,6 @@ main (int argc,
   gchar *conn_path;
 
   tp_tests_abort_after (10);
-  g_type_init ();
   dbus = tp_tests_dbus_daemon_dup_or_die ();
 
   MYASSERT (strlen (LONG_ACCOUNT_IS_LONG) == 256, "");
diff --git a/tests/dbus/message-mixin.c b/tests/dbus/message-mixin.c
index 7f526ec..8e46b41 100644
--- a/tests/dbus/message-mixin.c
+++ b/tests/dbus/message-mixin.c
@@ -219,7 +219,6 @@ main (int argc,
   GHashTable *parameters;
 
   tp_tests_abort_after (10);
-  g_type_init ();
   tp_debug_set_flags ("all");
   dbus = tp_tests_dbus_daemon_dup_or_die ();
 
diff --git a/tests/dbus/params-cm.c b/tests/dbus/params-cm.c
index 0b7b761..91f3702 100644
--- a/tests/dbus/params-cm.c
+++ b/tests/dbus/params-cm.c
@@ -59,7 +59,6 @@ setup (Test *test,
   TpBaseConnectionManager *service_cm_as_base;
   gboolean ok;
 
-  g_type_init ();
   tp_debug_set_flags ("all");
 
   test->mainloop = g_main_loop_new (NULL, FALSE);
diff --git a/tests/dbus/protocol-objects.c b/tests/dbus/protocol-objects.c
index b1c0fda..f33122d 100644
--- a/tests/dbus/protocol-objects.c
+++ b/tests/dbus/protocol-objects.c
@@ -46,7 +46,6 @@ setup (Test *test,
   TpBaseConnectionManager *service_cm_as_base;
   gboolean ok;
 
-  g_type_init ();
   tp_debug_set_flags ("all");
 
   test->mainloop = g_main_loop_new (NULL, FALSE);
diff --git a/tests/dbus/self-presence.c b/tests/dbus/self-presence.c
index c9ed473..2efa5fd 100644
--- a/tests/dbus/self-presence.c
+++ b/tests/dbus/self-presence.c
@@ -236,7 +236,6 @@ main (int argc,
   /* Setup */
 
   tp_tests_abort_after (10);
-  g_type_init ();
   tp_debug_set_flags ("all");
   dbus = tp_tests_dbus_daemon_dup_or_die ();
 
diff --git a/tests/dbus/text-mixin.c b/tests/dbus/text-mixin.c
index b4f494e..51bc6e1 100644
--- a/tests/dbus/text-mixin.c
+++ b/tests/dbus/text-mixin.c
@@ -94,7 +94,6 @@ main (int argc,
   TpHandle handle;
 
   tp_tests_abort_after (10);
-  g_type_init ();
   /* tp_debug_set_flags ("all"); */
   dbus = tp_tests_dbus_daemon_dup_or_die ();
 
diff --git a/tests/dbus/text-respawn.c b/tests/dbus/text-respawn.c
index 46b99aa..6de9f5b 100644
--- a/tests/dbus/text-respawn.c
+++ b/tests/dbus/text-respawn.c
@@ -96,7 +96,6 @@ main (int argc,
   TpHandle handle;
 
   tp_tests_abort_after (10);
-  g_type_init ();
   /* tp_debug_set_flags ("all"); */
   dbus = tp_tests_dbus_daemon_dup_or_die ();
 
diff --git a/tests/dbus/unsupported-interface.c b/tests/dbus/unsupported-interface.c
index 98da098..43c8523 100644
--- a/tests/dbus/unsupported-interface.c
+++ b/tests/dbus/unsupported-interface.c
@@ -37,7 +37,6 @@ static void
 setup (Fixture *f,
     gconstpointer data)
 {
-  g_type_init ();
   tp_debug_set_flags ("all");
   f->dbus = tp_tests_dbus_daemon_dup_or_die ();
 
diff --git a/tests/debug-domain.c b/tests/debug-domain.c
index 37ef418..d4dfb29 100644
--- a/tests/debug-domain.c
+++ b/tests/debug-domain.c
@@ -54,8 +54,6 @@ int main (int argc, char **argv)
 #ifdef ENABLE_DEBUG
   TestItem i;
 
-  g_type_init ();
-
   tp_debug_set_flags ("all");
 
   g_log_set_default_handler (handler, NULL);
diff --git a/tests/dtmf-player.c b/tests/dtmf-player.c
index 33eb99c..1f00f61 100644
--- a/tests/dtmf-player.c
+++ b/tests/dtmf-player.c
@@ -96,8 +96,6 @@ static void
 setup (Fixture *f,
     gconstpointer nil G_GNUC_UNUSED)
 {
-  g_type_init ();
-
   f->dtmf_player = tp_dtmf_player_new ();
   g_assert (f->dtmf_player != NULL);
 
diff --git a/tests/enums.c b/tests/enums.c
index 17ec4b4..251050b 100644
--- a/tests/enums.c
+++ b/tests/enums.c
@@ -22,8 +22,6 @@ test_tp_contact_feature (void)
 {
   GEnumClass *klass;
 
-  g_type_init ();
-
   klass = g_type_class_ref (TP_TYPE_CONTACT_FEATURE);
 
   g_assert (klass != NULL);
@@ -40,8 +38,6 @@ test_tp_dbus_error (void)
 {
   GEnumClass *klass;
 
-  g_type_init ();
-
   klass = g_type_class_ref (TP_TYPE_DBUS_ERROR);
 
   g_assert (klass != NULL);
diff --git a/tests/gnio-util.c b/tests/gnio-util.c
index 6ac758a..1a5bd1d 100644
--- a/tests/gnio-util.c
+++ b/tests/gnio-util.c
@@ -302,7 +302,6 @@ test_sockaddr_to_variant_abstract_unix (void)
 int
 main (int argc, char **argv)
 {
-  g_type_init ();
   dbus_g_type_specialized_init ();
 
   test_variant_to_sockaddr_ipv4 ();
diff --git a/tests/intset.c b/tests/intset.c
index f92af36..1630138 100644
--- a/tests/intset.c
+++ b/tests/intset.c
@@ -63,8 +63,6 @@ int main (int argc, char **argv)
   TpIntset *ab_symmdiff, *ab_expected_symmdiff;
   GValue *value;
 
-  g_type_init ();
-
   g_assert (tp_intset_is_empty (set1));
   g_assert_cmpuint (tp_intset_size (set1), ==, 0);
 
diff --git a/tests/lib/util.c b/tests/lib/util.c
index 6dd6dd4..d5751f4 100644
--- a/tests/lib/util.c
+++ b/tests/lib/util.c
@@ -84,8 +84,6 @@ start_dbus_session (void)
 {
   g_assert (test_dbus == NULL);
 
-  g_type_init ();
-
   g_test_dbus_unset ();
 
   /* GLib 2.36 does not unset STARTER env variables but tp-glib are using them.
@@ -379,7 +377,6 @@ void
 tp_tests_init (int *argc,
     char ***argv)
 {
-  g_type_init ();
   tp_tests_abort_after (10);
   tp_debug_set_flags ("all");
 
diff --git a/tests/signal-connect-object.c b/tests/signal-connect-object.c
index 90a8677..fa1c9e5 100644
--- a/tests/signal-connect-object.c
+++ b/tests/signal-connect-object.c
@@ -60,7 +60,6 @@ static void
 setup (Test *test,
     gconstpointer data)
 {
-  g_type_init ();
   tp_debug_set_flags ("all");
 
   test->caught = 0;
diff --git a/tests/util-cxx.cpp b/tests/util-cxx.cpp
index 3b2a6b5..b8b822e 100644
--- a/tests/util-cxx.cpp
+++ b/tests/util-cxx.cpp
@@ -28,8 +28,6 @@ int main (int argc, char **argv)
   GObject *o;
   GHashTable *h;
 
-  g_type_init ();
-
   o = (GObject *) g_file_new_for_path ("/");
   tp_clear_object (&o);
 
diff --git a/tests/util.c b/tests/util.c
index 1bf9533..3b0b7c9 100644
--- a/tests/util.c
+++ b/tests/util.c
@@ -297,8 +297,6 @@ int main (int argc, char **argv)
   GPtrArray *ptrarray;
   gchar *string;
 
-  g_type_init ();
-
   g_assert (!tp_strdiff (NULL, NULL));
   g_assert (tp_strdiff ("badger", NULL));
   g_assert (tp_strdiff (NULL, "badger"));
diff --git a/tools/glib-errors-check-gen.py b/tools/glib-errors-check-gen.py
index fad261e..3cc8a5a 100644
--- a/tools/glib-errors-check-gen.py
+++ b/tools/glib-errors-check-gen.py
@@ -17,7 +17,6 @@ class Generator(object):
         print('  GEnumValue *value_by_name;')
         print('  GEnumValue *value_by_nick;')
         print('')
-        print('  g_type_init ();')
         print('  klass = g_type_class_ref (TP_TYPE_ERROR);')
 
         for error in self.errors.getElementsByTagNameNS(NS_TP, 'error'):

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-telepathy/telepathy-glib.git



More information about the Pkg-telepathy-commits mailing list