Permalink
Browse files

session: give wayland sessions priority

If two sessions have the same name, give the wayland one
priority, unless wayland sessions are being ignored.

https://bugzilla.gnome.org/show_bug.cgi?id=757715
  • Loading branch information...
halfline committed Nov 9, 2015
1 parent 26006da commit 6cd2d248250f08b033fac6dffdc95e2dc83ffb4a
Showing with 6 additions and 7 deletions.
  1. +6 −7 daemon/gdm-session.c
@@ -338,23 +338,22 @@ static const char **
get_system_session_dirs (GdmSession *self)
{
static const char *search_dirs[] = {
#ifdef ENABLE_WAYLAND_SUPPORT
DATADIR "/wayland-sessions/",
#endif
"/etc/X11/sessions/",
DMCONFDIR "/Sessions/",
DATADIR "/gdm/BuiltInSessions/",
DATADIR "/xsessions/",
#ifdef ENABLE_WAYLAND_SUPPORT
NULL,
#endif
NULL
};
#ifdef ENABLE_WAYLAND_SUPPORT
if (!self->priv->ignore_wayland) {
search_dirs[G_N_ELEMENTS (search_dirs) - 1] = DATADIR "/wayland-sessions/";
} else {
search_dirs[G_N_ELEMENTS (search_dirs) - 1] = NULL;
if (self->priv->ignore_wayland) {
return search_dirs + 1;
}
#endif
return search_dirs;
}

0 comments on commit 6cd2d24

Please sign in to comment.