[gdm] gdm-x-session: pass display location to dbus-daemon
- From: Ray Strode <halfline src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gdm] gdm-x-session: pass display location to dbus-daemon
- Date: Sun, 22 Feb 2015 21:56:30 +0000 (UTC)
commit 9bac8121debeefe3ec25a8fb0a005e0cd4c7a394
Author: Mantas Mikulėnas <grawity gmail com>
Date: Sun Feb 22 22:19:37 2015 +0200
gdm-x-session: pass display location to dbus-daemon
The DISPLAY and XAUTHORITY environment variables need to be
set in the bus daemon environment so that programs activated via
the session bus can access the display.
https://bugzilla.gnome.org/show_bug.cgi?id=744946
daemon/gdm-x-session.c | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
---
diff --git a/daemon/gdm-x-session.c b/daemon/gdm-x-session.c
index c3c638e..dfd6016 100644
--- a/daemon/gdm-x-session.c
+++ b/daemon/gdm-x-session.c
@@ -385,6 +385,10 @@ spawn_bus (State *state,
arguments = g_ptr_array_new ();
launcher = g_subprocess_launcher_new (G_SUBPROCESS_FLAGS_NONE);
+
+ g_subprocess_launcher_setenv (launcher, "DISPLAY", state->display_name, TRUE);
+ g_subprocess_launcher_setenv (launcher, "XAUTHORITY", state->auth_file, TRUE);
+
g_subprocess_launcher_take_fd (launcher, pipe_fds[1], BUS_ADDRESS_FILENO);
bus_address_fd_string = g_strdup_printf ("%d", BUS_ADDRESS_FILENO);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]