Update patch based on latest change
Related: https://issues.redhat.com/browse/RHEL-129305
This commit is contained in:
parent
73e397b24c
commit
e3063519c8
@ -5,42 +5,15 @@ Subject: [PATCH 1/3] manager: allow multiple xdmcp logins for the same user
|
||||
|
||||
---
|
||||
common/gdm-settings-keys.h | 1 +
|
||||
daemon/gdm-manager.c | 71 ++++++++++++++++++++++++++++----------
|
||||
daemon/gdm-manager.c | 72 ++++++++++++++++++++++++++++----------
|
||||
data/gdm.schemas.in | 5 +++
|
||||
3 files changed, 59 insertions(+), 18 deletions(-)
|
||||
3 files changed, 60 insertions(+), 18 deletions(-)
|
||||
|
||||
diff --git a/common/gdm-settings-keys.h b/common/gdm-settings-keys.h
|
||||
index 87685d3c..4b3a1ffe 100644
|
||||
index 87685d3..4b3a1ff 100644
|
||||
--- a/common/gdm-settings-keys.h
|
||||
+++ b/common/gdm-settings-keys.h
|
||||
@@ -30,37 +30,38 @@ G_BEGIN_DECLS
|
||||
#define GDM_KEY_AUTO_LOGIN_ENABLE "daemon/AutomaticLoginEnable"
|
||||
#define GDM_KEY_AUTO_LOGIN_USER "daemon/AutomaticLogin"
|
||||
#define GDM_KEY_TIMED_LOGIN_ENABLE "daemon/TimedLoginEnable"
|
||||
#define GDM_KEY_TIMED_LOGIN_USER "daemon/TimedLogin"
|
||||
#define GDM_KEY_TIMED_LOGIN_DELAY "daemon/TimedLoginDelay"
|
||||
#define GDM_KEY_INITIAL_SETUP_ENABLE "daemon/InitialSetupEnable"
|
||||
#define GDM_KEY_PREFERRED_DISPLAY_SERVER "daemon/PreferredDisplayServer"
|
||||
#define GDM_KEY_WAYLAND_ENABLE "daemon/WaylandEnable"
|
||||
#define GDM_KEY_XORG_ENABLE "daemon/XorgEnable"
|
||||
|
||||
#define GDM_KEY_DEBUG "debug/Enable"
|
||||
|
||||
#define GDM_KEY_INCLUDE "greeter/Include"
|
||||
#define GDM_KEY_EXCLUDE "greeter/Exclude"
|
||||
#define GDM_KEY_INCLUDE_ALL "greeter/IncludeAll"
|
||||
|
||||
#define GDM_KEY_DISALLOW_TCP "security/DisallowTCP"
|
||||
#define GDM_KEY_ALLOW_REMOTE_AUTOLOGIN "security/AllowRemoteAutoLogin"
|
||||
|
||||
#define GDM_KEY_XDMCP_ENABLE "xdmcp/Enable"
|
||||
#define GDM_KEY_SHOW_LOCAL_GREETER "xdmcp/ShowLocalGreeter"
|
||||
#define GDM_KEY_MAX_PENDING "xdmcp/MaxPending"
|
||||
#define GDM_KEY_MAX_SESSIONS "xdmcp/MaxSessions"
|
||||
#define GDM_KEY_MAX_WAIT "xdmcp/MaxWait"
|
||||
#define GDM_KEY_DISPLAYS_PER_HOST "xdmcp/DisplaysPerHost"
|
||||
#define GDM_KEY_UDP_PORT "xdmcp/Port"
|
||||
#define GDM_KEY_INDIRECT "xdmcp/HonorIndirect"
|
||||
@@ -57,6 +57,7 @@ G_BEGIN_DECLS
|
||||
#define GDM_KEY_MAX_WAIT_INDIRECT "xdmcp/MaxWaitIndirect"
|
||||
#define GDM_KEY_PING_INTERVAL "xdmcp/PingIntervalSeconds"
|
||||
#define GDM_KEY_WILLING "xdmcp/Willing"
|
||||
@ -48,42 +21,11 @@ index 87685d3c..4b3a1ffe 100644
|
||||
|
||||
#define GDM_KEY_MULTICAST "chooser/Multicast"
|
||||
#define GDM_KEY_MULTICAST_ADDR "chooser/MulticastAddr"
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* _GDM_SETTINGS_KEYS_H */
|
||||
diff --git a/daemon/gdm-manager.c b/daemon/gdm-manager.c
|
||||
index e1bc62d7..08c3cc17 100644
|
||||
index 681c9f6..2be7d2b 100644
|
||||
--- a/daemon/gdm-manager.c
|
||||
+++ b/daemon/gdm-manager.c
|
||||
@@ -566,93 +566,106 @@ get_display_and_details_for_bus_sender (GdmManager *self,
|
||||
*out_tty = get_tty_for_session_id (session_id, &error);
|
||||
|
||||
if (error != NULL) {
|
||||
g_debug ("GdmManager: Error while retrieving tty for session: %s",
|
||||
error->message);
|
||||
g_clear_error (&error);
|
||||
}
|
||||
}
|
||||
|
||||
display = gdm_display_store_find (self->priv->display_store,
|
||||
lookup_by_session_id,
|
||||
(gpointer) session_id);
|
||||
|
||||
out:
|
||||
if (out_display != NULL) {
|
||||
*out_display = display;
|
||||
}
|
||||
|
||||
g_free (session_id);
|
||||
}
|
||||
|
||||
static gboolean
|
||||
switch_to_compatible_user_session (GdmManager *manager,
|
||||
GdmSession *session,
|
||||
gboolean fail_if_already_switched)
|
||||
{
|
||||
gboolean res;
|
||||
@@ -597,7 +597,7 @@ switch_to_compatible_user_session (GdmManager *manager,
|
||||
gboolean ret;
|
||||
const char *username;
|
||||
const char *seat_id;
|
||||
@ -92,7 +34,7 @@ index e1bc62d7..08c3cc17 100644
|
||||
GdmSession *existing_session;
|
||||
|
||||
ret = FALSE;
|
||||
|
||||
@@ -605,31 +605,44 @@ switch_to_compatible_user_session (GdmManager *manager,
|
||||
username = gdm_session_get_username (session);
|
||||
seat_id = gdm_session_get_display_seat_id (session);
|
||||
|
||||
@ -154,34 +96,7 @@ index e1bc62d7..08c3cc17 100644
|
||||
ret = TRUE;
|
||||
|
||||
out:
|
||||
return ret;
|
||||
}
|
||||
|
||||
static GdmDisplay *
|
||||
get_display_for_user_session (GdmSession *session)
|
||||
{
|
||||
return g_object_get_data (G_OBJECT (session), "gdm-display");
|
||||
}
|
||||
|
||||
static GdmSession *
|
||||
get_user_session_for_display (GdmDisplay *display)
|
||||
{
|
||||
if (display == NULL) {
|
||||
return NULL;
|
||||
}
|
||||
|
||||
return g_object_get_data (G_OBJECT (display), "gdm-user-session");
|
||||
}
|
||||
|
||||
static gboolean
|
||||
add_session_record (GdmManager *manager,
|
||||
GdmSession *session,
|
||||
GPid pid,
|
||||
SessionRecord record)
|
||||
{
|
||||
const char *username;
|
||||
char *display_name, *hostname, *display_device, *display_seat_id;
|
||||
@@ -1129,6 +1142,21 @@ open_temporary_reauthentication_channel (GdmManager *self,
|
||||
@@ -1077,6 +1090,21 @@ open_temporary_reauthentication_channel (GdmManager *self,
|
||||
return g_strdup (address);
|
||||
}
|
||||
|
||||
@ -203,7 +118,7 @@ index e1bc62d7..08c3cc17 100644
|
||||
static gboolean
|
||||
is_session_graphical (const char *session_id)
|
||||
{
|
||||
@@ -1237,6 +1265,14 @@ gdm_manager_handle_open_reauthentication_channel (GdmDBusManager *manager
|
||||
@@ -1188,6 +1216,14 @@ gdm_manager_handle_open_reauthentication_channel (GdmDBusManager *manager
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
@ -219,37 +134,10 @@ index e1bc62d7..08c3cc17 100644
|
||||
g_debug ("GdmManager: looking for login screen session for user %s on seat %s", username, seat_id);
|
||||
session = find_session_for_user_on_seat (self,
|
||||
diff --git a/data/gdm.schemas.in b/data/gdm.schemas.in
|
||||
index a1035f95..929d13d9 100644
|
||||
index a1035f9..929d13d 100644
|
||||
--- a/data/gdm.schemas.in
|
||||
+++ b/data/gdm.schemas.in
|
||||
@@ -112,33 +112,38 @@
|
||||
<schema>
|
||||
<key>xdmcp/DisplaysPerHost</key>
|
||||
<signature>i</signature>
|
||||
<default>1</default>
|
||||
</schema>
|
||||
<schema>
|
||||
<key>xdmcp/Port</key>
|
||||
<signature>i</signature>
|
||||
<default>177</default>
|
||||
</schema>
|
||||
<schema>
|
||||
<key>xdmcp/HonorIndirect</key>
|
||||
<signature>b</signature>
|
||||
<default>true</default>
|
||||
</schema>
|
||||
<schema>
|
||||
<key>xdmcp/MaxWaitIndirect</key>
|
||||
<signature>i</signature>
|
||||
<default>30</default>
|
||||
</schema>
|
||||
<schema>
|
||||
<key>xdmcp/PingIntervalSeconds</key>
|
||||
<signature>i</signature>
|
||||
<default>0</default>
|
||||
</schema>
|
||||
<schema>
|
||||
<key>xdmcp/Willing</key>
|
||||
@@ -139,6 +139,11 @@
|
||||
<signature>s</signature>
|
||||
<default>@gdmconfdir@/Xwilling</default>
|
||||
</schema>
|
||||
@ -262,5 +150,5 @@ index a1035f95..929d13d9 100644
|
||||
</gdmschemafile>
|
||||
|
||||
--
|
||||
2.37.3
|
||||
2.51.0
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user