mirror of
https://github.com/tmate-io/tmate.git
synced 2025-08-18 01:20:17 +02:00
Clear pollfds first.
This commit is contained in:
3
server.c
3
server.c
@@ -1,4 +1,4 @@
|
||||
/* $Id: server.c,v 1.126 2009-03-05 20:24:41 nicm Exp $ */
|
||||
/* $Id: server.c,v 1.127 2009-03-27 08:46:02 nicm Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net>
|
||||
@@ -249,6 +249,7 @@ server_main(const char *srv_path, int srv_fd)
|
||||
}
|
||||
nfds += ARRAY_LENGTH(&clients) * 2;
|
||||
pfds = xrealloc(pfds, nfds, sizeof *pfds);
|
||||
memset(pfds, 0, nfds * sizeof *pfds);
|
||||
pfd = pfds;
|
||||
|
||||
/* Fill server socket. */
|
||||
|
Reference in New Issue
Block a user