Hello community,

here is the log from the commit of package gdm for openSUSE:Factory checked in 
at 2017-10-21 20:17:21
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/gdm (Old)
 and      /work/SRC/openSUSE:Factory/.gdm.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "gdm"

Sat Oct 21 20:17:21 2017 rev:199 rq:535507 version:3.26.1

Changes:
--------
--- /work/SRC/openSUSE:Factory/gdm/gdm.changes  2017-10-20 14:41:23.304821454 
+0200
+++ /work/SRC/openSUSE:Factory/.gdm.new/gdm.changes     2017-10-21 
20:17:22.643358421 +0200
@@ -1,0 +2,6 @@
+Wed Oct 18 06:37:37 UTC 2017 - xw...@suse.com
+
+- Add gdm-ignore-duplicate-session.patch: Fix gdm session entries
+  duplicate (bsc#1060627).
+
+-------------------------------------------------------------------

New:
----
  gdm-ignore-duplicate-session.patch

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ gdm.spec ++++++
--- /var/tmp/diff_new_pack.OuP6Tx/_old  2017-10-21 20:17:23.583314406 +0200
+++ /var/tmp/diff_new_pack.OuP6Tx/_new  2017-10-21 20:17:23.587314218 +0200
@@ -56,6 +56,8 @@
 Patch34:        gdm-default-wm.patch
 # PATCH-FIX-OPENSUSE gdm-xauthlocalhostname.patch bnc#538064 vu...@novell.com 
-- Set XAUTHLOCALHOSTNAME to current hostname when we authenticate, for local 
logins, to avoid issues in the session in case the hostname changes later one. 
See comment 24 in the bug.
 Patch35:        gdm-xauthlocalhostname.patch
+# PATCH-FIX-OPENSUSE gdm-ignore-duplicate-session.patch xw...@suse.com -- gdm 
sessions entries duplicate
+Patch36:        gdm-ignore-duplicate-session.patch
 # PATCH-FIX-UPSTREAM gdm-plymouth-vt1.patch bnc#881676 fcro...@suse.com -- 
switch to VT1 when quitting if gdm was starting with plymouth running
 Patch41:        gdm-plymouth-vt1.patch
 # PATCH-FIX-UPSTREAM gdm-fails-to-restart-gnome-shell.patch bsc#981976 
bgo#769969 ty...@suse.com -- Gdm should stop after a few times fails
@@ -199,6 +201,7 @@
 %patch9 -p1
 %patch34 -p1
 %patch35 -p1
+%patch36 -p1
 %patch41 -p1
 %patch42 -p1
 %if !0%{?is_opensuse}

++++++ gdm-ignore-duplicate-session.patch ++++++
diff --git a/libgdm/gdm-sessions.c b/libgdm/gdm-sessions.c
index 4a5434ed..08829f6f 100644
--- a/libgdm/gdm-sessions.c
+++ b/libgdm/gdm-sessions.c
@@ -184,9 +184,22 @@ collect_sessions_from_directory (const char *dirname)
         g_dir_close (dir);
 }
 
+static gboolean
+find_translated_name (const char     *id,
+                      GdmSessionFile *session,
+                      char           *translated_name)
+{
+        if (g_str_equal (id, "default"))
+                return FALSE;
+
+        return g_str_equal (session->translated_name, translated_name) ? TRUE 
: FALSE;
+}
+
 static void
 collect_sessions (void)
 {
+        GdmSessionFile *session;
+        char           *translated_name = NULL;
         int         i;
         const char *xorg_search_dirs[] = {
                 "/etc/X11/sessions/",
@@ -223,6 +236,16 @@ collect_sessions (void)
                 collect_sessions_from_directory (wayland_search_dirs [i]);
         }
 #endif
+
+        session = g_hash_table_lookup (gdm_available_sessions_map, "default");
+        if (session)
+                translated_name = session->translated_name;
+
+        if (translated_name) {
+                session = g_hash_table_find (gdm_available_sessions_map, 
(GHRFunc)find_translated_name, translated_name);
+                if (session)
+                        g_hash_table_remove (gdm_available_sessions_map, 
session->id);
+        }
 }
 
 /**

Reply via email to