From 533882ab771afb049c7205fd8214fe655cd5fa48 Mon Sep 17 00:00:00 2001 From: Sergio Costas Date: Mon, 28 Sep 2020 20:39:41 +0200 Subject: [PATCH] wayland: Fix refcount error The Meta.WaylandClient constructor receives a GSubprocessLauncher as a parameter, and stores it internally. Unfortunately, its refcount value isn't increased, which results in the object being released twice. This patch fixes this bug. Fix https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1454 --- src/wayland/meta-wayland-client.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/wayland/meta-wayland-client.c b/src/wayland/meta-wayland-client.c index bba7ee1f8..01aa4c328 100644 --- a/src/wayland/meta-wayland-client.c +++ b/src/wayland/meta-wayland-client.c @@ -129,7 +129,7 @@ meta_wayland_client_new (GSubprocessLauncher *launcher, } client = g_object_new (META_TYPE_WAYLAND_CLIENT, NULL); - client->launcher = launcher; + client->launcher = g_object_ref (launcher); return client; }