summaryrefslogtreecommitdiffstats
path: root/usr.sbin/httpd/src
diff options
context:
space:
mode:
authorderaadt <deraadt@openbsd.org>2002-05-06 19:35:26 +0000
committerderaadt <deraadt@openbsd.org>2002-05-06 19:35:26 +0000
commit4a078b3f0ff8f6000470cb8ceb1eea5978f607af (patch)
treebbab83d25ace6974fbbfc37ba29711d8ce13eaee /usr.sbin/httpd/src
parentsyslog() paranoia; never pass in a non-const buffer w/o using "%s" (diff)
downloadwireguard-openbsd-4a078b3f0ff8f6000470cb8ceb1eea5978f607af.tar.xz
wireguard-openbsd-4a078b3f0ff8f6000470cb8ceb1eea5978f607af.zip
do not install a SIGSEGV handler
Diffstat (limited to 'usr.sbin/httpd/src')
-rw-r--r--usr.sbin/httpd/src/main/http_main.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/usr.sbin/httpd/src/main/http_main.c b/usr.sbin/httpd/src/main/http_main.c
index 648db553e75..29be0125a4c 100644
--- a/usr.sbin/httpd/src/main/http_main.c
+++ b/usr.sbin/httpd/src/main/http_main.c
@@ -3309,8 +3309,10 @@ static void set_signals(void)
#elif defined(SA_RESETHAND)
sa.sa_flags = SA_RESETHAND;
#endif
+#ifdef SIGSEGV_CHECK
if (sigaction(SIGSEGV, &sa, NULL) < 0)
ap_log_error(APLOG_MARK, APLOG_WARNING, server_conf, "sigaction(SIGSEGV)");
+#endif /* SIGSEGV_CHECK */
#ifdef SIGBUS
if (sigaction(SIGBUS, &sa, NULL) < 0)
ap_log_error(APLOG_MARK, APLOG_WARNING, server_conf, "sigaction(SIGBUS)");
@@ -3362,7 +3364,9 @@ static void set_signals(void)
ap_log_error(APLOG_MARK, APLOG_WARNING, server_conf, "sigaction(SIGUSR1)");
#else
if (!one_process) {
+#ifdef SIGSEGV_CHECK
signal(SIGSEGV, sig_coredump);
+#endif /* SIGSEGV_CHECK */
#ifdef SIGBUS
signal(SIGBUS, sig_coredump);
#endif /* SIGBUS */