From 5d48375212d816bb9e4d23efdc155ec77dbe927d Mon Sep 17 00:00:00 2001 From: rbuj Date: Thu, 25 Mar 2021 12:09:51 +0100 Subject: window-props: g_memdup is dreprecated from glib 2.68 --- src/core/window-props.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'src/core') diff --git a/src/core/window-props.c b/src/core/window-props.c index ed1d5c0c..2004c6a0 100644 --- a/src/core/window-props.c +++ b/src/core/window-props.c @@ -1605,8 +1605,14 @@ meta_display_init_window_prop_hooks (MetaDisplay *display) { 0 }, }; - MetaWindowPropHooks *table = g_memdup (hooks, sizeof (hooks)), - *cursor = table; + MetaWindowPropHooks *table, *cursor; + +#if GLIB_CHECK_VERSION (2, 68, 0) + table = g_memdup2 (hooks, sizeof (hooks)); +#else + table = g_memdup (hooks, sizeof (hooks)); +#endif + cursor = table; g_assert (display->prop_hooks == NULL); -- cgit v1.2.1