diff options
author | Davi Arnaut <Davi.Arnaut@Sun.COM> | 2009-11-10 22:39:06 -0200 |
---|---|---|
committer | Davi Arnaut <Davi.Arnaut@Sun.COM> | 2009-11-10 22:39:06 -0200 |
commit | 1c3c72ce178f8a0139066d90836e2b9e11324723 (patch) | |
tree | 210e5fd8ecf6fd5749ff4857899693ec9ed00e1b /vio | |
parent | 891dffa32293a1700bb940f55825488d86915010 (diff) | |
download | mariadb-git-1c3c72ce178f8a0139066d90836e2b9e11324723.tar.gz |
The FIONREAD macro could expand to a expression which
is invalid to preporcessor conditionals. Instead use
the autoconf generated macro to test the presence.
Diffstat (limited to 'vio')
-rw-r--r-- | vio/viosocket.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/vio/viosocket.c b/vio/viosocket.c index 055112f944e..aaaa8ceba97 100644 --- a/vio/viosocket.c +++ b/vio/viosocket.c @@ -372,6 +372,7 @@ void vio_in_addr(Vio *vio, struct in_addr *in) static my_bool socket_poll_read(my_socket sd, uint timeout) { #ifdef __WIN__ + int res; my_socket fd= sd; fd_set readfds, errorfds; struct timeval tm; @@ -424,7 +425,7 @@ static my_bool socket_peek_read(Vio *vio, uint *bytes) return TRUE; *bytes= len; return FALSE; -#elif FIONREAD +#elif FIONREAD_IN_SYS_IOCTL int len; if (ioctl(vio->sd, FIONREAD, &len) < 0) return TRUE; |