From d80a8a37935248eee6ad6f9256e1c89693c9335d Mon Sep 17 00:00:00 2001 From: Ray Strode Date: Tue, 28 Aug 2018 10:08:56 -0400 Subject: session: make sure conversation is closed before its freed Right now if the session-worker crashes, we fail to close the worker's dbus connection. This commit addresses the problem by making sure the conversation is explicitly closed at the time it's freed. Closes https://gitlab.gnome.org/GNOME/gdm/issues/388 --- daemon/gdm-session.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'daemon/gdm-session.c') diff --git a/daemon/gdm-session.c b/daemon/gdm-session.c index 600da0f3..04f879a7 100644 --- a/daemon/gdm-session.c +++ b/daemon/gdm-session.c @@ -185,6 +185,8 @@ static gboolean gdm_session_is_wayland_session (GdmSession *self); static void update_session_type (GdmSession *self); static void set_session_type (GdmSession *self, const char *session_type); +static void close_conversation (GdmSessionConversation *conversation); + static guint signals [LAST_SIGNAL] = { 0, }; G_DEFINE_TYPE (GdmSession, @@ -1820,6 +1822,8 @@ setup_outside_server (GdmSession *self) static void free_conversation (GdmSessionConversation *conversation) { + close_conversation (conversation); + if (conversation->job != NULL) { g_warning ("Freeing conversation '%s' with active job", conversation->service_name); } -- cgit v1.2.1