From 2b245c965c6c6dcfa55a8a77b967b90fac9bcb8b Mon Sep 17 00:00:00 2001 From: Maciej Bartczak <39600846+maciekbartczak@users.noreply.github.com> Date: Sun, 29 Dec 2024 09:27:59 +0100 Subject: [PATCH] Invalidate the timer when the surface is destroyed --- src/apprt/gtk/Surface.zig | 1 + 1 file changed, 1 insertion(+) diff --git a/src/apprt/gtk/Surface.zig b/src/apprt/gtk/Surface.zig index 115b7e13b..81564f1a3 100644 --- a/src/apprt/gtk/Surface.zig +++ b/src/apprt/gtk/Surface.zig @@ -650,6 +650,7 @@ pub fn deinit(self: *Surface) void { // and therefore the unfocused_overlay has been destroyed as well. c.g_object_unref(self.im_context); if (self.cursor) |cursor| c.g_object_unref(cursor); + if (self.update_title_timer) |timer| _ = c.g_source_remove(timer); self.resize_overlay.deinit(); }