summaryrefslogtreecommitdiffstats
path: root/sshd.c
diff options
context:
space:
mode:
authordtucker@openbsd.org <dtucker@openbsd.org>2018-02-11 21:16:56 +0000
committerDamien Miller <djm@mindrot.org>2018-02-13 09:29:09 +1100
commit05046d907c211cb9b4cd21b8eff9e7a46cd6c5ab (patch)
tree12b3f77675e807c5b9958c80bdb4b7c94b6db9bb /sshd.c
parent3c51143c639ac686687c7acf9b373b8c08195ffb (diff)
upstream Don't reset signal handlers inside handlers.
The signal handlers from the original ssh1 code on which OpenSSH is based assume unreliable signals and reinstall their handlers. Since OpenBSD (and pretty much every current system) has reliable signals this is not needed. In the unlikely even that -portable is still being used on such systems we will deal with it in the compat layer. ok deraadt@ OpenBSD-Commit-ID: f53a1015cb6908431b92116130d285d71589612c
Diffstat (limited to 'sshd.c')
-rw-r--r--sshd.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/sshd.c b/sshd.c
index 77231c33..17931068 100644
--- a/sshd.c
+++ b/sshd.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: sshd.c,v 1.503 2018/01/23 20:00:58 stsp Exp $ */
+/* $OpenBSD: sshd.c,v 1.504 2018/02/11 21:16:56 dtucker Exp $ */
/*
* Author: Tatu Ylonen <ylo@cs.hut.fi>
* Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
@@ -283,7 +283,6 @@ sighup_handler(int sig)
int save_errno = errno;
received_sighup = 1;
- signal(SIGHUP, sighup_handler);
errno = save_errno;
}
@@ -333,8 +332,6 @@ main_sigchld_handler(int sig)
while ((pid = waitpid(-1, &status, WNOHANG)) > 0 ||
(pid < 0 && errno == EINTR))
;
-
- signal(SIGCHLD, main_sigchld_handler);
errno = save_errno;
}