From 8178465c1a2adc81513c35d5d0419f092421c174 Mon Sep 17 00:00:00 2001 From: Benjamin Otte Date: Sun, 16 Apr 2023 16:57:48 +0200 Subject: [PATCH] testsuite: Fix broken test to not unref surfaces twice The test doesn't hold 2 references, it holds only one. The reason one unref can cause a leak is that some backends - like X11 - only destroy the surface once the DestroyNotify event from the X server has come in. --- testsuite/gtk/shortcuts.c | 1 - 1 file changed, 1 deletion(-) diff --git a/testsuite/gtk/shortcuts.c b/testsuite/gtk/shortcuts.c index 10a7913faa..f4895c5d2e 100644 --- a/testsuite/gtk/shortcuts.c +++ b/testsuite/gtk/shortcuts.c @@ -360,7 +360,6 @@ test_trigger_trigger (void) } gdk_surface_destroy (surface); - g_object_unref (surface); g_object_unref (trigger[0]); g_object_unref (trigger[1]);