summaryrefslogtreecommitdiff
path: root/daemon
diff options
context:
space:
mode:
authorRay Strode <rstrode@redhat.com>2014-04-07 14:22:10 -0400
committerRay Strode <rstrode@redhat.com>2014-04-14 15:02:27 -0400
commitce40d34d71beb5e946b5f424cd53a181ff831c59 (patch)
tree5dbead9c1b04bc03bfc042ce08209185acc53e71 /daemon
parent243ede3395e2745254dcef913e0b4bc97af37be5 (diff)
downloadgdm-ce40d34d71beb5e946b5f424cd53a181ff831c59.tar.gz
session: don't set DISPLAY for sessions that bring their own
We only want to set DISPLAY if the user session is sharing the display with the login screen. https://bugzilla.gnome.org/show_bug.cgi?id=728204
Diffstat (limited to 'daemon')
-rw-r--r--daemon/gdm-session.c18
1 files changed, 11 insertions, 7 deletions
diff --git a/daemon/gdm-session.c b/daemon/gdm-session.c
index 805072b5..50014c01 100644
--- a/daemon/gdm-session.c
+++ b/daemon/gdm-session.c
@@ -2319,6 +2319,7 @@ set_up_session_language (GdmSession *self)
static void
set_up_session_environment (GdmSession *self)
{
+ GdmSessionDisplayMode display_mode;
gchar *desktop_names;
gdm_session_set_environment_variable (self,
@@ -2338,14 +2339,17 @@ set_up_session_environment (GdmSession *self)
set_up_session_language (self);
- gdm_session_set_environment_variable (self,
- "DISPLAY",
- self->priv->display_name);
-
- if (self->priv->user_x11_authority_file != NULL) {
+ display_mode = gdm_session_get_display_mode (self);
+ if (display_mode == GDM_SESSION_DISPLAY_MODE_REUSE_VT) {
gdm_session_set_environment_variable (self,
- "XAUTHORITY",
- self->priv->user_x11_authority_file);
+ "DISPLAY",
+ self->priv->display_name);
+
+ if (self->priv->user_x11_authority_file != NULL) {
+ gdm_session_set_environment_variable (self,
+ "XAUTHORITY",
+ self->priv->user_x11_authority_file);
+ }
}
if (g_getenv ("WINDOWPATH") != NULL) {