From fc0875a4a0e383bafc1aaaf9f25f8c90bda38660 Mon Sep 17 00:00:00 2001 From: Luiz Augusto von Dentz Date: Fri, 2 Apr 2021 10:50:53 -0700 Subject: obex: Fix warnings cause by using of deprecated APIs obexd/src/main.c: In function 'main': obexd/src/main.c:237:13: warning: Deprecated pre-processor symbol 237 | if (g_thread_supported() == FALSE) | ^~~~~~~~~~~~~~~~~~~~~~~ obexd/src/main.c:238:3: warning: 'g_thread_init' is deprecated [-Wdeprecated-declarations] 238 | g_thread_init(NULL); | ^~~~~~~~~~~~~ In file included from /usr/include/glib-2.0/glib.h:111, from obexd/src/main.c:31: /usr/include/glib-2.0/glib/deprecated/gthread.h:261:10: note: declared here 261 | void g_thread_init (gpointer vtable); | ^~~~~~~~~~~~~ --- obexd/plugins/phonebook-tracker.c | 1 - obexd/src/main.c | 5 ----- 2 files changed, 6 deletions(-) (limited to 'obexd') diff --git a/obexd/plugins/phonebook-tracker.c b/obexd/plugins/phonebook-tracker.c index 30f945b84..71a91c1ea 100644 --- a/obexd/plugins/phonebook-tracker.c +++ b/obexd/plugins/phonebook-tracker.c @@ -1421,7 +1421,6 @@ done: int phonebook_init(void) { - g_thread_init(NULL); g_type_init(); return 0; diff --git a/obexd/src/main.c b/obexd/src/main.c index 629a3b4c1..04284c9e1 100644 --- a/obexd/src/main.c +++ b/obexd/src/main.c @@ -233,11 +233,6 @@ int main(int argc, char *argv[]) GError *err = NULL; guint signal; -#ifdef NEED_THREADS - if (g_thread_supported() == FALSE) - g_thread_init(NULL); -#endif - context = g_option_context_new(NULL); g_option_context_add_main_entries(context, options, NULL); -- cgit v1.2.1