summaryrefslogtreecommitdiffstats
path: root/gdm/patch/disable-fatal-criticals.patch
blob: 8af6636f8d0f907eed29095428a665b6b6c90350 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
From fc6ee4aa6d71d2c448a9b62aca24ba318163c590 Mon Sep 17 00:00:00 2001
From: Ray Strode <rstrode@redhat.com>
Date: Tue, 28 Jun 2011 12:51:51 -0400
Subject: [PATCH] common: don't tank on criticals

Tiny (or not so tiny) bugs in components below GDM in the stack
can lead to critical warnings.

In development releases, GDM by default will crash when encountering
a critical warning.

Losing the login screen is a big deal.  We shouldn't automatically subject
our users to "can't log in" in order to highlight bugs in development
releases.

This commit removes fatal criticals by default.
---
 common/gdm-common.c                   |    9 ---------
 common/gdm-common.h                   |    1 -
 daemon/factory-slave-main.c           |    2 --
 daemon/main.c                         |    2 --
 daemon/product-slave-main.c           |    2 --
 daemon/session-worker-main.c          |    2 --
 daemon/simple-slave-main.c            |    2 --
 daemon/xdmcp-chooser-slave-main.c     |    2 --
 gui/simple-chooser/chooser-main.c     |    2 --
 gui/simple-chooser/gdm-host-chooser.c |    2 --
 gui/simple-greeter/greeter-main.c     |    2 --
 11 files changed, 0 insertions(+), 28 deletions(-)

diff --git a/common/gdm-common.c b/common/gdm-common.c
index 7a4e26d..865341a 100644
--- a/common/gdm-common.c
+++ b/common/gdm-common.c
@@ -65,15 +65,6 @@ gdm_is_version_unstable (void)
         return unstable;
 }
 
-void
-gdm_set_fatal_warnings_if_unstable (void)
-{
-        if (gdm_is_version_unstable ()) {
-                g_setenv ("G_DEBUG", "fatal_criticals", FALSE);
-                g_log_set_always_fatal (G_LOG_LEVEL_CRITICAL);
-        }
-}
-
 gboolean
 gdm_get_pwent_for_name (const char     *name,
                         struct passwd **pwentp)
diff --git a/common/gdm-common.h b/common/gdm-common.h
index 06300c8..41ddf1c 100644
--- a/common/gdm-common.h
+++ b/common/gdm-common.h
@@ -31,7 +31,6 @@
 G_BEGIN_DECLS
 
 gboolean       gdm_is_version_unstable            (void);
-void           gdm_set_fatal_warnings_if_unstable (void);
 
 int            gdm_wait_on_pid           (int pid);
 int            gdm_wait_on_and_kill_pid  (int pid,
diff --git a/daemon/factory-slave-main.c b/daemon/factory-slave-main.c
index 9caab1c..2441260 100644
--- a/daemon/factory-slave-main.c
+++ b/daemon/factory-slave-main.c
@@ -183,8 +183,6 @@ main (int    argc,
         textdomain (GETTEXT_PACKAGE);
         setlocale (LC_ALL, "");
 
-        gdm_set_fatal_warnings_if_unstable ();
-
         g_type_init ();
 
         context = g_option_context_new (_("GNOME Display Manager Slave"));
diff --git a/daemon/main.c b/daemon/main.c
index 5b8d66b..2ffb779 100644
--- a/daemon/main.c
+++ b/daemon/main.c
@@ -543,8 +543,6 @@ main (int    argc,
 
         ret = 1;
 
-        gdm_set_fatal_warnings_if_unstable ();
-
         g_type_init ();
 
         context = g_option_context_new (_("GNOME Display Manager"));
diff --git a/daemon/product-slave-main.c b/daemon/product-slave-main.c
index b0ab03f..b8e4755 100644
--- a/daemon/product-slave-main.c
+++ b/daemon/product-slave-main.c
@@ -187,8 +187,6 @@ main (int    argc,
         textdomain (GETTEXT_PACKAGE);
         setlocale (LC_ALL, "");
 
-        gdm_set_fatal_warnings_if_unstable ();
-
         g_type_init ();
 
         context = g_option_context_new (_("GNOME Display Manager Slave"));
diff --git a/daemon/session-worker-main.c b/daemon/session-worker-main.c
index 35b4463..9d40b8d 100644
--- a/daemon/session-worker-main.c
+++ b/daemon/session-worker-main.c
@@ -151,8 +151,6 @@ main (int    argc,
 
         g_type_init ();
 
-        gdm_set_fatal_warnings_if_unstable ();
-
         /* Translators: worker is a helper process that does the work
            of starting up a session */
         context = g_option_context_new (_("GNOME Display Manager Session Worker"));
diff --git a/daemon/simple-slave-main.c b/daemon/simple-slave-main.c
index 7751b61..057492b 100644
--- a/daemon/simple-slave-main.c
+++ b/daemon/simple-slave-main.c
@@ -187,8 +187,6 @@ main (int    argc,
         textdomain (GETTEXT_PACKAGE);
         setlocale (LC_ALL, "");
 
-        gdm_set_fatal_warnings_if_unstable ();
-
         g_type_init ();
 
         context = g_option_context_new (_("GNOME Display Manager Slave"));
diff --git a/daemon/xdmcp-chooser-slave-main.c b/daemon/xdmcp-chooser-slave-main.c
index f86ea89..ea54210 100644
--- a/daemon/xdmcp-chooser-slave-main.c
+++ b/daemon/xdmcp-chooser-slave-main.c
@@ -189,8 +189,6 @@ main (int    argc,
         textdomain (GETTEXT_PACKAGE);
         setlocale (LC_ALL, "");
 
-        gdm_set_fatal_warnings_if_unstable ();
-
         g_type_init ();
 
         context = g_option_context_new (_("GNOME Display Manager Slave"));
diff --git a/gui/simple-chooser/chooser-main.c b/gui/simple-chooser/chooser-main.c
index ac1edd6..2978a23 100644
--- a/gui/simple-chooser/chooser-main.c
+++ b/gui/simple-chooser/chooser-main.c
@@ -233,8 +233,6 @@ main (int argc, char *argv[])
 
         setlocale (LC_ALL, "");
 
-        gdm_set_fatal_warnings_if_unstable ();
-
         g_type_init ();
 
         gdm_log_init ();
diff --git a/gui/simple-chooser/gdm-host-chooser.c b/gui/simple-chooser/gdm-host-chooser.c
index 371ba28..1f5f9c6 100644
--- a/gui/simple-chooser/gdm-host-chooser.c
+++ b/gui/simple-chooser/gdm-host-chooser.c
@@ -232,8 +232,6 @@ main (int argc, char *argv[])
 
         setlocale (LC_ALL, "");
 
-        gdm_set_fatal_warnings_if_unstable ();
-
         g_type_init ();
 
         gdm_log_init ();
diff --git a/gui/simple-greeter/greeter-main.c b/gui/simple-greeter/greeter-main.c
index aa165fa..a2c533e 100644
--- a/gui/simple-greeter/greeter-main.c
+++ b/gui/simple-greeter/greeter-main.c
@@ -252,8 +252,6 @@ main (int argc, char *argv[])
 
         setlocale (LC_ALL, "");
 
-        gdm_set_fatal_warnings_if_unstable ();
-
         g_type_init ();
 
         gdm_profile_start ("Initializing settings client");
-- 
1.7.5.4