1 |
tetromino 11/12/31 08:34:35 |
2 |
|
3 |
Added: gdm-3.2.1.1-pam-fix-2.patch |
4 |
gdm-3.2.1.1-pam-fix-1.patch |
5 |
Log: |
6 |
Add upstream patches to fix login problems with slow pam modules. Add default-enabled fallback USE flag to pull in metacity (bug #395295, thanks to Octavio Ruiz (Ta^3) for reporting). Use a better systemd service file (bug #396317, thanks to Michał Górny). Ship systemd service file and pam.d files in FILESDIR instead of a separate tarball; these are small files and unlikely to change (bug #396317, comment 8). Punt unused elibc_glibc from IUSE. Move gnome2_src_prepare after eautoreconf. |
7 |
Forced to drop arm keyword due to gnome-session dependency (bug #390345). |
8 |
|
9 |
(Portage version: 2.2.0_alpha84/cvs/Linux x86_64) |
10 |
|
11 |
Revision Changes Path |
12 |
1.1 gnome-base/gdm/files/gdm-3.2.1.1-pam-fix-2.patch |
13 |
|
14 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/gnome-base/gdm/files/gdm-3.2.1.1-pam-fix-2.patch?rev=1.1&view=markup |
15 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/gnome-base/gdm/files/gdm-3.2.1.1-pam-fix-2.patch?rev=1.1&content-type=text/plain |
16 |
|
17 |
Index: gdm-3.2.1.1-pam-fix-2.patch |
18 |
=================================================================== |
19 |
From 9c874ee6f595906faf59f891f20492530888804b Mon Sep 17 00:00:00 2001 |
20 |
From: Ray Strode <rstrode@××××××.com> |
21 |
Date: Mon, 24 Oct 2011 16:45:46 -0400 |
22 |
Subject: [PATCH] worker: don't block SIGTERM |
23 |
|
24 |
If the slave tells us to go away, we should go away, |
25 |
not wait a PAM module decides to let us get back to the |
26 |
main loop. |
27 |
--- |
28 |
daemon/session-worker-main.c | 1 - |
29 |
1 files changed, 0 insertions(+), 1 deletions(-) |
30 |
|
31 |
diff --git a/daemon/session-worker-main.c b/daemon/session-worker-main.c |
32 |
index 9d40b8d..42fcd52 100644 |
33 |
--- a/daemon/session-worker-main.c |
34 |
+++ b/daemon/session-worker-main.c |
35 |
@@ -188,7 +188,6 @@ main (int argc, |
36 |
gdm_signal_handler_set_fatal_func (signal_handler, |
37 |
(GDestroyNotify)g_main_loop_quit, |
38 |
main_loop); |
39 |
- gdm_signal_handler_add (signal_handler, SIGTERM, signal_cb, NULL); |
40 |
gdm_signal_handler_add (signal_handler, SIGINT, signal_cb, NULL); |
41 |
gdm_signal_handler_add (signal_handler, SIGILL, signal_cb, NULL); |
42 |
gdm_signal_handler_add (signal_handler, SIGBUS, signal_cb, NULL); |
43 |
-- |
44 |
1.7.8.1 |
45 |
|
46 |
|
47 |
|
48 |
|
49 |
1.1 gnome-base/gdm/files/gdm-3.2.1.1-pam-fix-1.patch |
50 |
|
51 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/gnome-base/gdm/files/gdm-3.2.1.1-pam-fix-1.patch?rev=1.1&view=markup |
52 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/gnome-base/gdm/files/gdm-3.2.1.1-pam-fix-1.patch?rev=1.1&content-type=text/plain |
53 |
|
54 |
Index: gdm-3.2.1.1-pam-fix-1.patch |
55 |
=================================================================== |
56 |
From 9c354795892b8c5fd661a35653991a88fabc76bf Mon Sep 17 00:00:00 2001 |
57 |
From: Ray Strode <rstrode@××××××.com> |
58 |
Date: Mon, 24 Oct 2011 16:39:45 -0400 |
59 |
Subject: [PATCH] daemon: Don't emit session-exited when non-authenticated |
60 |
worker fails |
61 |
|
62 |
Sometimes PAM modules are finicky and don't die when you tell them to. |
63 |
Instead they fail some seconds later. |
64 |
|
65 |
If a user successfully logs in with one stack and another stack is |
66 |
being troublesome, then we'll get notified about it finishing up |
67 |
after the user is already logged in. |
68 |
|
69 |
When that happens, we erroneously assume the stack finishing is the |
70 |
stack the user's session is running on and then proceed to log the |
71 |
user out. |
72 |
|
73 |
This commit makes us be a little more careful about our bookkeeping |
74 |
so we can ignore failures from slow PAM modules. |
75 |
--- |
76 |
daemon/gdm-session-direct.c | 23 ++++++++++++++--------- |
77 |
1 files changed, 14 insertions(+), 9 deletions(-) |
78 |
|
79 |
diff --git a/daemon/gdm-session-direct.c b/daemon/gdm-session-direct.c |
80 |
index e178985..bb2bff8 100644 |
81 |
--- a/daemon/gdm-session-direct.c |
82 |
+++ b/daemon/gdm-session-direct.c |
83 |
@@ -91,10 +91,11 @@ struct _GdmSessionDirectPrivate |
84 |
|
85 |
GHashTable *conversations; |
86 |
|
87 |
+ GdmSessionConversation *session_conversation; |
88 |
+ |
89 |
GList *pending_connections; |
90 |
|
91 |
GPid session_pid; |
92 |
- guint32 is_running : 1; |
93 |
|
94 |
/* object lifetime scope */ |
95 |
char *id; |
96 |
@@ -1073,7 +1074,7 @@ gdm_session_direct_handle_session_started (GdmSessionDirect *session, |
97 |
pid); |
98 |
|
99 |
session->priv->session_pid = pid; |
100 |
- session->priv->is_running = TRUE; |
101 |
+ session->priv->session_conversation = conversation; |
102 |
|
103 |
_gdm_session_session_started (GDM_SESSION (session), conversation->service_name, pid); |
104 |
|
105 |
@@ -1129,7 +1130,7 @@ gdm_session_direct_handle_session_exited (GdmSessionDirect *session, |
106 |
g_debug ("GdmSessionDirect: Emitting 'session-exited' signal with exit code '%d'", |
107 |
code); |
108 |
|
109 |
- session->priv->is_running = FALSE; |
110 |
+ session->priv->session_conversation = NULL; |
111 |
_gdm_session_session_exited (GDM_SESSION (session), code); |
112 |
|
113 |
return DBUS_HANDLER_RESULT_HANDLED; |
114 |
@@ -1158,7 +1159,7 @@ gdm_session_direct_handle_session_died (GdmSessionDirect *session, |
115 |
g_debug ("GdmSessionDirect: Emitting 'session-died' signal with signal number '%d'", |
116 |
code); |
117 |
|
118 |
- session->priv->is_running = FALSE; |
119 |
+ session->priv->session_conversation = NULL; |
120 |
_gdm_session_session_died (GDM_SESSION (session), code); |
121 |
|
122 |
return DBUS_HANDLER_RESULT_HANDLED; |
123 |
@@ -1790,7 +1791,7 @@ worker_exited (GdmSessionWorkerJob *job, |
124 |
g_debug ("GdmSessionDirect: Worker job exited: %d", code); |
125 |
|
126 |
g_object_ref (conversation->job); |
127 |
- if (conversation->session->priv->is_running) { |
128 |
+ if (conversation->session->priv->session_conversation == conversation) { |
129 |
_gdm_session_session_exited (GDM_SESSION (conversation->session), code); |
130 |
} |
131 |
|
132 |
@@ -1819,7 +1820,7 @@ worker_died (GdmSessionWorkerJob *job, |
133 |
g_debug ("GdmSessionDirect: Worker job died: %d", signum); |
134 |
|
135 |
g_object_ref (conversation->job); |
136 |
- if (conversation->session->priv->is_running) { |
137 |
+ if (conversation->session->priv->session_conversation == conversation) { |
138 |
_gdm_session_session_died (GDM_SESSION (conversation->session), signum); |
139 |
} |
140 |
|
141 |
@@ -2442,6 +2443,10 @@ stop_all_other_conversations (GdmSessionDirect *session, |
142 |
g_strdup (conversation_to_keep->service_name), |
143 |
conversation_to_keep); |
144 |
} |
145 |
+ |
146 |
+ if (session->priv->session_conversation != conversation_to_keep) { |
147 |
+ session->priv->session_conversation = NULL; |
148 |
+ } |
149 |
} |
150 |
|
151 |
} |
152 |
@@ -2456,7 +2461,7 @@ gdm_session_direct_start_session (GdmSession *session, |
153 |
char *program; |
154 |
|
155 |
g_return_if_fail (session != NULL); |
156 |
- g_return_if_fail (impl->priv->is_running == FALSE); |
157 |
+ g_return_if_fail (impl->priv->session_conversation == NULL); |
158 |
|
159 |
conversation = find_conversation_by_name (impl, service_name); |
160 |
|
161 |
@@ -2504,7 +2509,7 @@ gdm_session_direct_close (GdmSession *session) |
162 |
|
163 |
g_debug ("GdmSessionDirect: Closing session"); |
164 |
|
165 |
- if (impl->priv->is_running) { |
166 |
+ if (impl->priv->session_conversation != NULL) { |
167 |
gdm_session_record_logout (impl->priv->session_pid, |
168 |
impl->priv->selected_user, |
169 |
impl->priv->display_hostname, |
170 |
@@ -2540,7 +2545,7 @@ gdm_session_direct_close (GdmSession *session) |
171 |
g_hash_table_remove_all (impl->priv->environment); |
172 |
|
173 |
impl->priv->session_pid = -1; |
174 |
- impl->priv->is_running = FALSE; |
175 |
+ impl->priv->session_conversation = NULL; |
176 |
} |
177 |
|
178 |
static void |
179 |
-- |
180 |
1.7.8.1 |