Win32: fix poll() return value
authorRémi Denis-Courmont <rdenis@simphalempin.com>
Sun, 18 Jan 2009 09:54:48 +0000 (11:54 +0200)
committerRémi Denis-Courmont <rdenis@simphalempin.com>
Sun, 18 Jan 2009 09:55:23 +0000 (11:55 +0200)
Spotted by Laurent

src/network/poll.c

index 6c9aec3..5590b36 100644 (file)
@@ -99,7 +99,7 @@ int vlc_poll (struct pollfd *fds, unsigned nfds, int timeout)
                 if (events.iErrorCode[FD_WRITE_BIT])
                     fds[i].revents |= POLLERR;
             }
-            if (fds[i].events)
+            if (fds[i].revents)
                 n++;
         }
         if (ret == 0)