gio: Use g_steal_handle_id() with signal unsubscriptions

This makes no functional changes, but does tidy the code up a bit and
means `g_steal_handle_id()` gets a bit more testing.

Signed-off-by: Philip Withnall <pwithnall@gnome.org>
This commit is contained in:
Philip Withnall
2024-10-08 13:55:22 +01:00
parent da5ce72171
commit 6b15af3c4c
15 changed files with 38 additions and 62 deletions

View File

@@ -437,8 +437,7 @@ g_fdo_notification_backend_dispose (GObject *object)
GDBusConnection *session_bus;
session_bus = G_NOTIFICATION_BACKEND (backend)->dbus_connection;
g_dbus_connection_signal_unsubscribe (session_bus, backend->notify_subscription);
backend->notify_subscription = 0;
g_dbus_connection_signal_unsubscribe (session_bus, g_steal_handle_id (&backend->notify_subscription));
}
if (backend->notifications)