ensure revents fields are initialized before calling poll()

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6476 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
Kevin P. Fleming
2005-08-31 22:12:23 +00:00
parent b67fced7ae
commit 050d6c7d34
4 changed files with 9 additions and 0 deletions

View File

@@ -436,8 +436,10 @@ static void *netconsole(void *vconsole)
for(;;) {
fds[0].fd = con->fd;
fds[0].events = POLLIN;
fds[0].revents = 0;
fds[1].fd = con->p[0];
fds[1].events = POLLIN;
fds[1].revents = 0;
res = poll(fds, 2, -1);
if (res < 0) {