Accepting request 909320 from GNOME:Factory

- Add gnome-session-exit-when-lost-name-on-bus.patch: gnome-session
  exit immediately when lost name on bus
  (bsc#1175622 glgo!GNOME/gnome-session!60, bsc#1188882). (forwarded request 909263 from xiaoguang_wang)

OBS-URL: https://build.opensuse.org/request/show/909320
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/gnome-session?expand=0&rev=196
This commit is contained in:
Dominique Leuenberger 2021-08-02 10:04:18 +00:00 committed by Git OBS Bridge
commit 87f690cea2
3 changed files with 47 additions and 0 deletions

View File

@ -0,0 +1,38 @@
diff --git a/gnome-session/gsm-manager.c b/gnome-session/gsm-manager.c
index 6839a02d..67b09d8a 100644
--- a/gnome-session/gsm-manager.c
+++ b/gnome-session/gsm-manager.c
@@ -1802,6 +1802,14 @@ gsm_manager_set_failsafe (GsmManager *manager,
manager->priv->failsafe = enabled;
}
+gboolean
+gsm_manager_get_dbus_disconnected (GsmManager *manager)
+{
+ g_return_val_if_fail (GSM_IS_MANAGER (manager), FALSE);
+
+ return manager->priv->dbus_disconnected;
+}
+
gboolean
gsm_manager_get_failsafe (GsmManager *manager)
{
diff --git a/gnome-session/main.c b/gnome-session/main.c
index 01f56667..51ea6975 100644
--- a/gnome-session/main.c
+++ b/gnome-session/main.c
@@ -83,8 +83,12 @@ on_name_lost (GDBusConnection *connection,
gpointer data)
{
if (connection == NULL) {
- g_warning ("Lost name on bus: %s", name);
- gsm_fail_whale_dialog_we_failed (TRUE, TRUE, NULL);
+ if (gsm_manager_get_dbus_disconnected (manager))
+ gsm_quit ();
+ else {
+ g_warning ("Lost name on bus: %s", name);
+ gsm_fail_whale_dialog_we_failed (TRUE, TRUE, NULL);
+ }
} else {
g_debug ("Calling name lost callback function");

View File

@ -1,3 +1,10 @@
-------------------------------------------------------------------
Fri Jul 30 01:01:37 UTC 2021 - Xiaoguang Wang <xiaoguang.wang@suse.com>
- Add gnome-session-exit-when-lost-name-on-bus.patch: gnome-session
exit immediately when lost name on bus
(bsc#1175622 glgo!GNOME/gnome-session!60, bsc#1188882).
------------------------------------------------------------------- -------------------------------------------------------------------
Fri Apr 30 12:35:06 UTC 2021 - Dominique Leuenberger <dimstar@opensuse.org> Fri Apr 30 12:35:06 UTC 2021 - Dominique Leuenberger <dimstar@opensuse.org>

View File

@ -28,6 +28,8 @@ Source1: gnome
Source2: gnome.desktop Source2: gnome.desktop
# PATCH-FIX-UPSTREAM gnome-session-better-handle-empty-xdg_session_type.patch bsc#1084756 bgo#794256 yfjiang@suse.com -- solution provided by msrb@suse.com using a more reasonable way to handle gpu acceleration check # PATCH-FIX-UPSTREAM gnome-session-better-handle-empty-xdg_session_type.patch bsc#1084756 bgo#794256 yfjiang@suse.com -- solution provided by msrb@suse.com using a more reasonable way to handle gpu acceleration check
Patch0: gnome-session-better-handle-empty-xdg_session_type.patch Patch0: gnome-session-better-handle-empty-xdg_session_type.patch
# PATCH-FIX-UPSTREAM gnome-session-exit-when-lost-name-on-bus.patch bsc#1175622 glgo!GNOME/gnome-session!60 xwang@suse.com -- gnome-session exit immediately when lost name on bus
Patch1: gnome-session-exit-when-lost-name-on-bus.patch
BuildRequires: docbook-xsl-stylesheets BuildRequires: docbook-xsl-stylesheets
BuildRequires: fdupes BuildRequires: fdupes