From d210e5fde6ea98e4d7363868e34733ab1c6cf00f Mon Sep 17 00:00:00 2001 From: Igor Babaev Date: Thu, 24 Sep 2009 23:42:43 -0700 Subject: Took care of mysql test suite failures on Windows. mysql-test/suite/rpl/t/rpl_binlog_corruption.test: Disabled the test for Windows (see bug #47639) mysql-test/suite/rpl/t/rpl_killed_ddl.test: Disabled the test for Windows (see bug #47638) vio/viosocket.c: Added an implementation of vio_poll_read for Windows. Winsock does not support the poll function. So the existing generic implementation of vio_poll_read could not be used for Windows. --- vio/viosocket.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'vio/viosocket.c') diff --git a/vio/viosocket.c b/vio/viosocket.c index 4c6cc428c52..fead2ca7c1c 100644 --- a/vio/viosocket.c +++ b/vio/viosocket.c @@ -361,7 +361,20 @@ void vio_in_addr(Vio *vio, struct in_addr *in) my_bool vio_poll_read(Vio *vio,uint timeout) { #ifndef HAVE_POLL +#if __WIN__ + int res; + struct fd_set fds; + struct timeval tv; + DBUG_ENTER("vio_poll"); + fds.fd_count= 1; + fds.fd_array[0]= vio->sd; + tv.tv_sec= timeout; + tv.tv_usec= 0; + res= select(1, &fds, NULL, NULL, &tv) ? 0 : 1; + DBUG_RETURN(res); +#else return 0; +#endif #else struct pollfd fds; int res; -- cgit v1.2.1