Poll loop: fix read of unused fds[]
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Fri, 1 Jul 2011 22:47:10 +0000 (23:47 +0100)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Fri, 1 Jul 2011 22:47:13 +0000 (23:47 +0100)
commit508bb58325dbacebda8dd6ec7703c5446c339d21
tree66914160d2a972334922e65130761f885a1da64b
parent4ff0a42ff7efe5cc1b36e9c5ff930609b3f56b86
Poll loop: fix read of unused fds[]

Commit 29672515
 portability: Work around Apple's bizarrely deficient poll() implementation
introduced a read of unitialised data in fds[], because it failed to
honour i->nfds which is 0 on the first iteration.

The symptom is that secnet may, on the first iteration, die due to
mistakenly seeing POLLNVAL.

Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
secnet.c