[PATCH] glib: remove invocations of g_type_init()
Aleksander Morgado
aleksander at aleksander.es
Tue Jun 27 08:13:19 UTC 2017
On 27/06/17 05:58, Ben Chan wrote:
> g_type_init() has been deprecated (and also marked with the attribute
> 'deprecated') since glib 2.36 as the type system is automatically
> initialized. Since the minimum version of glib required by libmbim is
> 2.36, calling g_type_init() isn't necessarily in the libmbim code.
> ---
Pushed to git master, thanks
> src/mbim-proxy/mbim-proxy.c | 4 ----
> src/mbimcli/mbimcli.c | 4 ----
> 2 files changed, 8 deletions(-)
>
> diff --git a/src/mbim-proxy/mbim-proxy.c b/src/mbim-proxy/mbim-proxy.c
> index 2e8eeb9..46f023e 100644
> --- a/src/mbim-proxy/mbim-proxy.c
> +++ b/src/mbim-proxy/mbim-proxy.c
> @@ -196,10 +196,6 @@ int main (int argc, char **argv)
>
> setlocale (LC_ALL, "");
>
> -#if !GLIB_CHECK_VERSION (2, 36, 0)
> - g_type_init ();
> -#endif
> -
> /* Setup option context, process it and destroy it */
> context = g_option_context_new ("- Proxy for MBIM devices");
> g_option_context_add_main_entries (context, main_entries, NULL);
> diff --git a/src/mbimcli/mbimcli.c b/src/mbimcli/mbimcli.c
> index a265895..76183fd 100644
> --- a/src/mbimcli/mbimcli.c
> +++ b/src/mbimcli/mbimcli.c
> @@ -372,10 +372,6 @@ int main (int argc, char **argv)
>
> setlocale (LC_ALL, "");
>
> -#if !GLIB_CHECK_VERSION (2, 36, 0)
> - g_type_init ();
> -#endif
> -
> /* Setup option context, process it and destroy it */
> context = g_option_context_new ("- Control MBIM devices");
> g_option_context_add_group (context,
>
--
Aleksander
https://aleksander.es
More information about the libmbim-devel
mailing list