Skip to content

Commit

Permalink
upstream: set num_listen_socks to 0 on close-all instead of -1,
Browse files Browse the repository at this point in the history
which interferes with the new poll()-based listen loop; spotted and debugged
by anton@+deraadt@

OpenBSD-Commit-ID: f7ab8ab124f615a2e0c45fee14c38d2f2abbabbd
  • Loading branch information
djmdjm committed Nov 17, 2021
1 parent fd93435 commit fd7e7de
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions sshd.c
@@ -1,4 +1,4 @@
/* $OpenBSD: sshd.c,v 1.579 2021/11/14 18:47:43 deraadt Exp $ */
/* $OpenBSD: sshd.c,v 1.580 2021/11/17 21:06:39 djm Exp $ */
/*
* Author: Tatu Ylonen <ylo@cs.hut.fi>
* Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
Expand Down Expand Up @@ -273,7 +273,7 @@ close_listen_socks(void)

for (i = 0; i < num_listen_socks; i++)
close(listen_socks[i]);
num_listen_socks = -1;
num_listen_socks = 0;
}

static void
Expand Down

0 comments on commit fd7e7de

Please sign in to comment.