Commit c4c03180 authored by Francois Gouget's avatar Francois Gouget Committed by Alexandre Julliard

server: Make sock_check_pollhup() more reliable on Solaris.

parent 5d657bfd
......@@ -203,7 +203,8 @@ static sock_shutdown_t sock_check_pollhup(void)
pfd.events = POLLIN;
pfd.revents = 0;
n = poll( &pfd, 1, 0 );
/* Solaris' poll() sometimes returns nothing if given a 0ms timeout here */
n = poll( &pfd, 1, 1 );
if ( n != 1 ) goto out; /* error or timeout */
if ( pfd.revents & POLLHUP )
ret = SOCK_SHUTDOWN_POLLHUP;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment