summaryrefslogtreecommitdiff
path: root/daemon/gdm-display.c
diff options
context:
space:
mode:
authorRay Strode <rstrode@redhat.com>2012-07-13 15:15:47 -0400
committerRay Strode <rstrode@redhat.com>2012-07-13 15:21:34 -0400
commit38ffd450c5a3e0bfe784294a81329dcdf443fb1f (patch)
treec88c0cda6bf443a2230f637f6e36e6bbc84ce269 /daemon/gdm-display.c
parentbb86a35ae5a3557b531ad6dbeccffa774aacf9d2 (diff)
downloadgdm-38ffd450c5a3e0bfe784294a81329dcdf443fb1f.tar.gz
daemon: driveby XDMCP crash fix
If the XDMCP chooser exits enough times, the whole daemon eventually tanks when the child watch function tries to access freed memory. This commit takes the hammer approach of adding a reference to the slave from the child watch func. It also makes sure that there isn't ever two slaves running for one display at the same time.
Diffstat (limited to 'daemon/gdm-display.c')
-rw-r--r--daemon/gdm-display.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/daemon/gdm-display.c b/daemon/gdm-display.c
index e885bdfb..be1d5e05 100644
--- a/daemon/gdm-display.c
+++ b/daemon/gdm-display.c
@@ -995,6 +995,8 @@ gdm_display_dispose (GObject *object)
}
if (display->priv->slave_proxy != NULL) {
+ gdm_slave_proxy_stop (display->priv->slave_proxy);
+
g_object_unref (display->priv->slave_proxy);
display->priv->slave_proxy = NULL;
}