[gnome-session/gnome-3-20] client: don't try to access client after it's vanished
- From: Ray Strode <halfline src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-session/gnome-3-20] client: don't try to access client after it's vanished
- Date: Tue, 15 Mar 2016 19:48:19 +0000 (UTC)
commit 657057f71cc8f40890fd14dae2f1354c8e3a7792
Author: Ray Strode <rstrode redhat com>
Date: Wed Mar 9 13:47:16 2016 -0500
client: don't try to access client after it's vanished
After we emit the disconnected signal on the client it's likely
to get freed, so don't try to use it from that point forward.
https://bugzilla.gnome.org/show_bug.cgi?id=763169
gnome-session/gsm-dbus-client.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/gnome-session/gsm-dbus-client.c b/gnome-session/gsm-dbus-client.c
index 598df4e..e5b9985 100644
--- a/gnome-session/gsm-dbus-client.c
+++ b/gnome-session/gsm-dbus-client.c
@@ -225,9 +225,11 @@ on_client_vanished (GDBusConnection *connection,
gpointer user_data)
{
GsmDBusClient *client = user_data;
- gsm_client_disconnected (GSM_CLIENT (client));
g_bus_unwatch_name (client->priv->watch_id);
+ client->priv->watch_id = 0;
+
+ gsm_client_disconnected (GSM_CLIENT (client));
}
static void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]