summaryrefslogtreecommitdiff
path: root/src/gpm-statistics.c
diff options
context:
space:
mode:
authorWilliam Brown <[email protected]>2012-11-18 16:32:32 +1030
committerWilliam Brown <[email protected]>2012-11-18 16:32:32 +1030
commitc4c747f87ce3fb6f41f25ed5ad7be0d75d30a5c1 (patch)
treef42dee39e85f8955fc2e5d7ee6ee0a8b98e9fed7 /src/gpm-statistics.c
parent1ea3233503f84366afd4e0a76e47afa258d17d04 (diff)
downloadmate-power-manager-c4c747f87ce3fb6f41f25ed5ad7be0d75d30a5c1.tar.bz2
mate-power-manager-c4c747f87ce3fb6f41f25ed5ad7be0d75d30a5c1.tar.xz
This adds checks for glib version, in regards to deprecated apis. see http://developer.gnome.org/glib/2.31/glib-Deprecated-Thread-APIs.html#g-thread-init
Diffstat (limited to 'src/gpm-statistics.c')
-rw-r--r--src/gpm-statistics.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/gpm-statistics.c b/src/gpm-statistics.c
index 3284067..4813d1f 100644
--- a/src/gpm-statistics.c
+++ b/src/gpm-statistics.c
@@ -1564,8 +1564,11 @@ main (int argc, char *argv[])
bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8");
textdomain (GETTEXT_PACKAGE);
+#if GLIB_CHECK_VERSION(2,32,0)
+#else
if (! g_thread_supported ())
g_thread_init (NULL);
+#endif
dbus_g_thread_init ();
g_type_init ();