mirror of
https://github.com/tmux/tmux.git
synced 2025-01-14 20:58:53 +00:00
Clear pollfds first.
This commit is contained in:
parent
12bb7436c3
commit
52fb9ca250
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>
|
* 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;
|
nfds += ARRAY_LENGTH(&clients) * 2;
|
||||||
pfds = xrealloc(pfds, nfds, sizeof *pfds);
|
pfds = xrealloc(pfds, nfds, sizeof *pfds);
|
||||||
|
memset(pfds, 0, nfds * sizeof *pfds);
|
||||||
pfd = pfds;
|
pfd = pfds;
|
||||||
|
|
||||||
/* Fill server socket. */
|
/* Fill server socket. */
|
||||||
|
Loading…
Reference in New Issue
Block a user