diff options
Diffstat (limited to 'x11-terms/gnome-terminal/files/gnome-terminal-2.26.3.1-partial-fix-dbus-error.patch')
-rw-r--r-- | x11-terms/gnome-terminal/files/gnome-terminal-2.26.3.1-partial-fix-dbus-error.patch | 75 |
1 files changed, 75 insertions, 0 deletions
diff --git a/x11-terms/gnome-terminal/files/gnome-terminal-2.26.3.1-partial-fix-dbus-error.patch b/x11-terms/gnome-terminal/files/gnome-terminal-2.26.3.1-partial-fix-dbus-error.patch new file mode 100644 index 000000000000..b6945651eb5f --- /dev/null +++ b/x11-terms/gnome-terminal/files/gnome-terminal-2.26.3.1-partial-fix-dbus-error.patch @@ -0,0 +1,75 @@ +Partial fix for Gentoo bug 268846, upstream is not interested in a complete fix +that allows gnome-terminal to work when gconf-daemon cannot be run. + +-- +From f41c3d14bdfd533109d7d75bdbb2e2a0ab59b60c Mon Sep 17 00:00:00 2001 +From: Christian Persch <chpe@gnome.org> +Date: Thu, 13 Aug 2009 12:31:11 +0000 +Subject: Be more lenient in the gconf daemon check + +Using gconf_ping_daemon() wasn't working right, since it returns FALSE +not only when the gconf daemon cannot be spawned, but also if the daemon +simply isn't running yet, but could be started without problems. Use +gconf_spawn_daemon() instead. Should fix problem reported in bug 564649 +comment 5. +--- +diff --git a/src/terminal.c b/src/terminal.c +index 41285e5..fc0cb2b 100644 +--- a/src/terminal.c ++++ b/src/terminal.c +@@ -236,8 +236,8 @@ get_factory_name_for_display (const char *display_name) + } + + /* Evil hack alert: this is exported from libgconf-2 but not in a public header */ +-extern gboolean gconf_ping_daemon (void); +- ++extern gboolean gconf_spawn_daemon(GError** err); ++ + int + main (int argc, char **argv) + { +@@ -329,7 +329,7 @@ main (int argc, char **argv) + { + g_printerr ("Failed to get the session bus: %s\nFalling back to non-factory mode.\n", + error->message); +- g_error_free (error); ++ g_clear_error (&error); + goto factory_disabled; + } + +@@ -353,7 +353,7 @@ main (int argc, char **argv) + &error)) + { + g_printerr ("Failed name request: %s\n", error->message); +- g_error_free (error); ++ g_clear_error (&error); + goto factory_disabled; + } + +@@ -419,7 +419,7 @@ main (int argc, char **argv) + { + /* Incompatible factory version, fall back, to new instance */ + g_printerr (_("Incompatible factory version; creating a new instance.\n")); +- g_error_free (error); ++ g_clear_error (&error); + + goto factory_disabled; + } +@@ -449,10 +449,13 @@ factory_disabled: + /* If the gconf daemon isn't available (e.g. because there's no dbus + * session bus running), we'd crash later on. Tell the user about it + * now, and exit. See bug #561663. ++ * Don't use gconf_ping_daemon() here since the server may just not ++ * be running yet, but able to be started. See comments on bug #564649. + */ +- if (!gconf_ping_daemon ()) ++ if (!gconf_spawn_daemon (&error)) + { +- g_printerr ("Failed to contact the GConf daemon; exiting.\n"); ++ g_printerr ("Failed to summon the GConf demon: %s\n", error->message); ++ g_error_free (error); + exit (1); + } + +-- +cgit v0.8.2 |