diff --git a/0001-gdm-session-settings-keep-a-ref-to-the-user.patch b/0001-gdm-session-settings-keep-a-ref-to-the-user.patch new file mode 100644 index 0000000..22e1583 --- /dev/null +++ b/0001-gdm-session-settings-keep-a-ref-to-the-user.patch @@ -0,0 +1,31 @@ +From 5a0c2afd7e2001a848101a8154d38fcf1b092963 Mon Sep 17 00:00:00 2001 +From: Ignacio Casal Quinteiro +Date: Fri, 14 Aug 2026 11:43:09 +0200 +Subject: [PATCH] gdm-session-settings: keep a ref to the user + +The user needs to keep a reference so it stays alive during +the signal emissions in case the manager decides to remove +the user internally. + +Part-of: +--- + daemon/gdm-session-settings.c | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +diff --git a/daemon/gdm-session-settings.c b/daemon/gdm-session-settings.c +index 33100a70c..07bb8e26f 100644 +--- a/daemon/gdm-session-settings.c ++++ b/daemon/gdm-session-settings.c +@@ -349,7 +349,8 @@ gdm_session_settings_load (GdmSessionSettings *settings, + } + + settings->user = act_user_manager_get_user (settings->user_manager, +- username); ++ username); ++ g_object_ref (settings->user); + + if (!act_user_is_loaded (settings->user)) { + g_signal_connect (settings->user, +-- +2.55.0 + diff --git a/gdm.spec b/gdm.spec index ccd54ba..08d663c 100644 --- a/gdm.spec +++ b/gdm.spec @@ -81,6 +81,10 @@ Patch: 0001-data-Add-PAM-substack-wrappers-to-prevent-auth-bypas.patch # https://gitlab.gnome.org/GNOME/gdm/-/merge_requests/374 Patch: 0001-session-Set-GDM_AUTH_SESSION_ID-env-var-for-PAM-conversations.patch +# RHEL-240871 +# https://gitlab.gnome.org/GNOME/gdm/-/merge_requests/392 +Patch: 0001-gdm-session-settings-keep-a-ref-to-the-user.patch + BuildRequires: dconf BuildRequires: desktop-file-utils BuildRequires: gettext-devel