[openssh-commits] [openssh] 01/05: upstream: Continue accept loop when pselect

git+noreply at mindrot.org git+noreply at mindrot.org
Thu Jun 10 20:53:28 AEST 2021


This is an automated email from the git hooks/post-receive script.

dtucker pushed a commit to branch master
in repository openssh.

commit 73f6f191f44440ca3049b9d3c8e5401d10b55097
Author: dtucker at openbsd.org <dtucker at openbsd.org>
Date:   Thu Jun 10 03:14:14 2021 +0000

    upstream: Continue accept loop when pselect
    
    returns -1, eg if it was interrupted by a signal.  This should prevent
    the hang discovered by sthen@ wherein sshd receives a SIGHUP while it has
    an unauthenticated child and goes on to a blocking read on a notify_pipe.
    feedback deraadt@, ok djm@
    
    OpenBSD-Commit-ID: 0243c1c5544fca0974dae92cd4079543a3fceaa0
---
 sshd.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/sshd.c b/sshd.c
index 7e80b174..6d645c4a 100644
--- a/sshd.c
+++ b/sshd.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: sshd.c,v 1.575 2021/06/06 11:34:16 djm Exp $ */
+/* $OpenBSD: sshd.c,v 1.576 2021/06/10 03:14:14 dtucker Exp $ */
 /*
  * Author: Tatu Ylonen <ylo at cs.hut.fi>
  * Copyright (c) 1995 Tatu Ylonen <ylo at cs.hut.fi>, Espoo, Finland
@@ -1213,7 +1213,7 @@ server_accept_loop(int *sock_in, int *sock_out, int *newsock, int *config_s)
 		if (ret == -1 && errno != EINTR)
 			error("pselect: %.100s", strerror(errno));
 		sigprocmask(SIG_SETMASK, &osigset, NULL);
-		if (received_sigterm)
+		if (ret == -1)
 			continue;
 
 		for (i = 0; i < options.max_startups; i++) {

-- 
To stop receiving notification emails like this one, please contact
djm at mindrot.org.


More information about the openssh-commits mailing list