[gdm] Remove handling of SIGSEGV/SIGFPE/SIGILL etc.
- From: Ray Strode <halfline src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gdm] Remove handling of SIGSEGV/SIGFPE/SIGILL etc.
- Date: Tue, 22 Jan 2013 16:56:37 +0000 (UTC)
commit 59d705966a50fe796b5ba7414697aa503476a7ec
Author: Colin Walters <walters verbum org>
Date: Mon Dec 3 13:24:07 2012 -0500
Remove handling of SIGSEGV/SIGFPE/SIGILL etc.
Modern operating systems have "crash catching" functionality; for
example, systemd comes with "systemd-coredump" which collects cores
automatically.
Attempting to handle these kinds of fatal signals internally is now
much worse, because the original source of the problem will be masked.
systemd won't collect a core file that would include a backtrace, for
example.
Also, with these removed, we can move forward porting to
g_unix_signal_add().
https://bugzilla.gnome.org/show_bug.cgi?id=676181
daemon/main.c | 9 ---------
daemon/session-worker-main.c | 22 ----------------------
daemon/simple-slave-main.c | 22 ----------------------
daemon/xdmcp-chooser-slave-main.c | 22 ----------------------
gui/simple-greeter/greeter-main.c | 9 ---------
5 files changed, 0 insertions(+), 84 deletions(-)
---
diff --git a/daemon/main.c b/daemon/main.c
index 62252aa..316e908 100644
--- a/daemon/main.c
+++ b/daemon/main.c
@@ -277,14 +277,6 @@ signal_cb (int signo,
ret = TRUE;
switch (signo) {
- case SIGFPE:
- case SIGPIPE:
- /* let the fatal signals interrupt us */
- g_debug ("Caught signal %d, shutting down abnormally.", signo);
- ret = FALSE;
-
- break;
-
case SIGINT:
case SIGTERM:
/* let the fatal signals interrupt us */
@@ -445,7 +437,6 @@ main (int argc,
gdm_signal_handler_add_fatal (signal_handler);
gdm_signal_handler_add (signal_handler, SIGTERM, signal_cb, NULL);
gdm_signal_handler_add (signal_handler, SIGINT, signal_cb, NULL);
- gdm_signal_handler_add (signal_handler, SIGFPE, signal_cb, NULL);
gdm_signal_handler_add (signal_handler, SIGHUP, signal_cb, NULL);
gdm_signal_handler_add (signal_handler, SIGUSR1, signal_cb, NULL);
diff --git a/daemon/session-worker-main.c b/daemon/session-worker-main.c
index e6b6dd0..57027cf 100644
--- a/daemon/session-worker-main.c
+++ b/daemon/session-worker-main.c
@@ -57,23 +57,6 @@ signal_cb (int signo,
ret = TRUE;
switch (signo) {
- case SIGSEGV:
- case SIGBUS:
- case SIGILL:
- case SIGABRT:
- g_debug ("Caught signal %d.", signo);
-
- ret = FALSE;
- break;
-
- case SIGFPE:
- case SIGPIPE:
- /* let the fatal signals interrupt us */
- g_debug ("Caught signal %d, shutting down abnormally.", signo);
- ret = FALSE;
-
- break;
-
case SIGINT:
case SIGTERM:
/* let the fatal signals interrupt us */
@@ -183,12 +166,7 @@ main (int argc,
(GDestroyNotify)g_main_loop_quit,
main_loop);
gdm_signal_handler_add (signal_handler, SIGINT, signal_cb, NULL);
- gdm_signal_handler_add (signal_handler, SIGILL, signal_cb, NULL);
- gdm_signal_handler_add (signal_handler, SIGBUS, signal_cb, NULL);
- gdm_signal_handler_add (signal_handler, SIGFPE, signal_cb, NULL);
gdm_signal_handler_add (signal_handler, SIGHUP, signal_cb, NULL);
- gdm_signal_handler_add (signal_handler, SIGSEGV, signal_cb, NULL);
- gdm_signal_handler_add (signal_handler, SIGABRT, signal_cb, NULL);
gdm_signal_handler_add (signal_handler, SIGUSR1, signal_cb, NULL);
g_main_loop_run (main_loop);
diff --git a/daemon/simple-slave-main.c b/daemon/simple-slave-main.c
index 3b18652..b6e6ee4 100644
--- a/daemon/simple-slave-main.c
+++ b/daemon/simple-slave-main.c
@@ -81,23 +81,6 @@ signal_cb (int signo,
ret = TRUE;
switch (signo) {
- case SIGSEGV:
- case SIGBUS:
- case SIGILL:
- case SIGABRT:
- g_debug ("Caught signal %d.", signo);
-
- ret = FALSE;
- break;
-
- case SIGFPE:
- case SIGPIPE:
- /* let the fatal signals interrupt us */
- g_debug ("Caught signal %d, shutting down abnormally.", signo);
- ret = FALSE;
-
- break;
-
case SIGINT:
case SIGTERM:
/* let the fatal signals interrupt us */
@@ -230,12 +213,7 @@ main (int argc,
main_loop);
gdm_signal_handler_add (signal_handler, SIGTERM, signal_cb, NULL);
gdm_signal_handler_add (signal_handler, SIGINT, signal_cb, NULL);
- gdm_signal_handler_add (signal_handler, SIGILL, signal_cb, NULL);
- gdm_signal_handler_add (signal_handler, SIGBUS, signal_cb, NULL);
- gdm_signal_handler_add (signal_handler, SIGFPE, signal_cb, NULL);
gdm_signal_handler_add (signal_handler, SIGHUP, signal_cb, NULL);
- gdm_signal_handler_add (signal_handler, SIGSEGV, signal_cb, NULL);
- gdm_signal_handler_add (signal_handler, SIGABRT, signal_cb, NULL);
gdm_signal_handler_add (signal_handler, SIGUSR1, signal_cb, NULL);
gdm_signal_handler_add (signal_handler, SIGUSR2, signal_cb, NULL);
diff --git a/daemon/xdmcp-chooser-slave-main.c b/daemon/xdmcp-chooser-slave-main.c
index 637848f..e6bd30c 100644
--- a/daemon/xdmcp-chooser-slave-main.c
+++ b/daemon/xdmcp-chooser-slave-main.c
@@ -80,23 +80,6 @@ signal_cb (int signo,
ret = TRUE;
switch (signo) {
- case SIGSEGV:
- case SIGBUS:
- case SIGILL:
- case SIGABRT:
- g_debug ("Caught signal %d.", signo);
-
- ret = FALSE;
- break;
-
- case SIGFPE:
- case SIGPIPE:
- /* let the fatal signals interrupt us */
- g_debug ("Caught signal %d, shutting down abnormally.", signo);
- ret = FALSE;
-
- break;
-
case SIGINT:
case SIGTERM:
/* let the fatal signals interrupt us */
@@ -223,12 +206,7 @@ main (int argc,
main_loop);
gdm_signal_handler_add (signal_handler, SIGTERM, signal_cb, NULL);
gdm_signal_handler_add (signal_handler, SIGINT, signal_cb, NULL);
- gdm_signal_handler_add (signal_handler, SIGILL, signal_cb, NULL);
- gdm_signal_handler_add (signal_handler, SIGBUS, signal_cb, NULL);
- gdm_signal_handler_add (signal_handler, SIGFPE, signal_cb, NULL);
gdm_signal_handler_add (signal_handler, SIGHUP, signal_cb, NULL);
- gdm_signal_handler_add (signal_handler, SIGSEGV, signal_cb, NULL);
- gdm_signal_handler_add (signal_handler, SIGABRT, signal_cb, NULL);
gdm_signal_handler_add (signal_handler, SIGUSR1, signal_cb, NULL);
gdm_signal_handler_add (signal_handler, SIGUSR2, signal_cb, NULL);
diff --git a/gui/simple-greeter/greeter-main.c b/gui/simple-greeter/greeter-main.c
index ba8efc0..d83493e 100644
--- a/gui/simple-greeter/greeter-main.c
+++ b/gui/simple-greeter/greeter-main.c
@@ -79,14 +79,6 @@ signal_cb (int signo,
ret = TRUE;
switch (signo) {
- case SIGFPE:
- case SIGPIPE:
- /* let the fatal signals interrupt us */
- g_debug ("Caught signal %d, shutting down abnormally.", signo);
- ret = FALSE;
-
- break;
-
case SIGINT:
case SIGTERM:
/* let the fatal signals interrupt us */
@@ -297,7 +289,6 @@ main (int argc, char *argv[])
gdm_signal_handler_add_fatal (signal_handler);
gdm_signal_handler_add (signal_handler, SIGTERM, signal_cb, NULL);
gdm_signal_handler_add (signal_handler, SIGINT, signal_cb, NULL);
- gdm_signal_handler_add (signal_handler, SIGFPE, signal_cb, NULL);
gdm_signal_handler_add (signal_handler, SIGHUP, signal_cb, NULL);
gdm_signal_handler_add (signal_handler, SIGUSR1, signal_cb, NULL);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]