- Don't ever try to autolaunch a bus if DISPLAY is unset

epel9
Ray Strode 17 years ago
parent 1dbcfeebcf
commit cd4f495d90

@ -7,7 +7,7 @@
Summary: A process-transparent configuration system Summary: A process-transparent configuration system
Name: GConf2 Name: GConf2
Version: 2.22.0 Version: 2.22.0
Release: 8%{?dist} Release: 9%{?dist}
License: LGPLv2+ License: LGPLv2+
Group: System Environment/Base Group: System Environment/Base
Source: http://download.gnome.org/sources/GConf/2.22/GConf-%{version}.tar.bz2 Source: http://download.gnome.org/sources/GConf/2.22/GConf-%{version}.tar.bz2
@ -160,6 +160,9 @@ fi
%{_libdir}/pkgconfig/* %{_libdir}/pkgconfig/*
%changelog %changelog
* Wed May 21 2008 Ray Strode <rstrode@redhat.com> - 2.22.0-9
- Don't ever try to autolaunch a bus if DISPLAY is unset
* Wed May 21 2008 Ray Strode <rstrode@redhat.com> - 2.22.0-8 * Wed May 21 2008 Ray Strode <rstrode@redhat.com> - 2.22.0-8
- If the session bus isn't running, assume local client side - If the session bus isn't running, assume local client side
access to the database (bug 446703) access to the database (bug 446703)

@ -754,13 +754,13 @@ diff -up /dev/null GConf-2.22.0/gconf/org.gnome.GConf.service.in
+ /* if the bus isn't running and we don't want to start gconfd then + /* if the bus isn't running and we don't want to start gconfd then
+ * we don't want to autolaunch the bus either, so bail early. + * we don't want to autolaunch the bus either, so bail early.
+ */ + */
+ if (g_getenv ("DBUS_SESSION_BUS_ADDRESS") == NULL && !start_if_not_found) { + if (g_getenv ("DBUS_SESSION_BUS_ADDRESS") == NULL
+ && (!start_if_not_found || g_getenv ("DISPLAY") == NULL)) {
+ if (failure_log) + if (failure_log)
+ g_string_append_printf (failure_log, + g_string_append_printf (failure_log,
+ _("Not running within active session")); + _("Not running within active session"));
+ return NULL; + return NULL;
+ } + }
+
dbus_error_init (&bus_error); dbus_error_init (&bus_error);
connection = dbus_bus_get (DBUS_BUS_SESSION, &bus_error); connection = dbus_bus_get (DBUS_BUS_SESSION, &bus_error);

Loading…
Cancel
Save