From a63e80ec64be268c2ed9883dd871aeaab39de9e5 Mon Sep 17 00:00:00 2001 From: Sebastian Keller Date: Fri, 24 Jan 2020 18:47:43 +0100 Subject: [PATCH] wayland: Avoid GVariant leak in set_gnome_env https://gitlab.gnome.org/GNOME/mutter/merge_requests/1020 --- src/wayland/meta-wayland.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/wayland/meta-wayland.c b/src/wayland/meta-wayland.c index 806c897c9..876b4925a 100644 --- a/src/wayland/meta-wayland.c +++ b/src/wayland/meta-wayland.c @@ -266,13 +266,14 @@ set_gnome_env (const char *name, { GDBusConnection *session_bus; GError *error = NULL; + g_autoptr (GVariant) result = NULL; setenv (name, value, TRUE); session_bus = g_bus_get_sync (G_BUS_TYPE_SESSION, NULL, NULL); g_assert (session_bus); - g_dbus_connection_call_sync (session_bus, + result = g_dbus_connection_call_sync (session_bus, "org.gnome.SessionManager", "/org/gnome/SessionManager", "org.gnome.SessionManager",