From 940fcb6701d055f49530f12c93371f0280efce80 Mon Sep 17 00:00:00 2001 From: Guus Sliepen Date: Thu, 13 Jun 2002 16:12:40 +0000 Subject: [PATCH] Reset listen_sockets after SIGHUP. --- src/net_setup.c | 4 +++- src/net_socket.c | 4 ++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/src/net_setup.c b/src/net_setup.c index d0d57daa..aa5b669e 100644 --- a/src/net_setup.c +++ b/src/net_setup.c @@ -17,7 +17,7 @@ along with this program; if not, write to the Free Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. - $Id: net_setup.c,v 1.1.2.18 2002/06/08 14:08:57 guus Exp $ + $Id: net_setup.c,v 1.1.2.19 2002/06/13 16:12:40 guus Exp $ */ #include "config.h" @@ -484,6 +484,8 @@ cp return -1; } + listen_sockets = 0; + for(aip = ai; aip; aip = aip->ai_next) { if((listen_socket[listen_sockets].tcp = setup_listen_socket((sockaddr_t *)aip->ai_addr)) < 0) diff --git a/src/net_socket.c b/src/net_socket.c index 089f0078..9af1cc94 100644 --- a/src/net_socket.c +++ b/src/net_socket.c @@ -17,7 +17,7 @@ along with this program; if not, write to the Free Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. - $Id: net_socket.c,v 1.1.2.14 2002/06/08 14:08:57 guus Exp $ + $Id: net_socket.c,v 1.1.2.15 2002/06/13 16:12:40 guus Exp $ */ #include "config.h" @@ -80,7 +80,7 @@ int maxtimeout = 900; int seconds_till_retry = 5; listen_socket_t listen_socket[MAXSOCKETS]; -int listen_sockets = 0; +int listen_sockets; /* Setup sockets */ -- 2.39.5