mirror of
https://github.com/nmap/nmap.git
synced 2025-12-26 17:39:03 +00:00
WSAPoll returns WSAEINVAL when there are no valid sockets in the fdarray parameter. Individual WSAPOLLFDs can be ignored by setting them to a negative value (just as with POSIX poll(2)), but there must be at least one valid (not-ignored) socket to check. Handled this by either returning error if the error was not EINVAL, or by checking each WSAPOLLFD in the fdarray; at the first valid one, return the error, since this was not the reason for the error. If none are valid, continue, ignoring the error.