summaryrefslogtreecommitdiff
path: root/include/my_global.h
diff options
context:
space:
mode:
authorunknown <SergeyV@selena.>2005-08-30 19:19:28 +0400
committerunknown <SergeyV@selena.>2005-08-30 19:19:28 +0400
commita8a5e98ec6a1170173d897b0da0d39866c79c7ba (patch)
treea7b1b47c1245fde5af125171897bbad4252ebc6a /include/my_global.h
parentf658a7a7c3616c5edec3b1e0a79427ca98b20fdb (diff)
downloadmariadb-git-a8a5e98ec6a1170173d897b0da0d39866c79c7ba.tar.gz
Fixes bug #5588. vio_was_interrupted() function was added to detect
read timeout properly on win32. include/my_global.h: Added win32 specific socket timeout error code. include/violite.h: Added vio_was_interrupted function that returns true if operation was not completed due to timeout. sql/mini_client.cc: added a check that replication read was not completed due to timeout. sql/net_serv.cc: net->last_errno should be equal to ER_NET_READ_INTERRUPTED in case if read operation was not completed due to timeout. vio/vio.c: added initialization code for vio_was_interrupted() function. vio/viosocket.c: Added vio_was_interrupted function that returns true if operation was not completed due to timeout.
Diffstat (limited to 'include/my_global.h')
-rw-r--r--include/my_global.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/my_global.h b/include/my_global.h
index e2a97667a1f..4b2e27aa3f6 100644
--- a/include/my_global.h
+++ b/include/my_global.h
@@ -760,6 +760,7 @@ typedef off_t os_off_t;
#define socket_errno WSAGetLastError()
#define SOCKET_EINTR WSAEINTR
#define SOCKET_EAGAIN WSAEINPROGRESS
+#define SOCKET_ETIMEDOUT WSAETIMEDOUT
#define SOCKET_EWOULDBLOCK WSAEINPROGRESS
#define SOCKET_ENFILE ENFILE
#define SOCKET_EMFILE EMFILE
@@ -767,6 +768,7 @@ typedef off_t os_off_t;
#define socket_errno sock_errno()
#define SOCKET_EINTR SOCEINTR
#define SOCKET_EAGAIN SOCEINPROGRESS
+#define SOCKET_ETIMEDOUT SOCKET_EINTR
#define SOCKET_EWOULDBLOCK SOCEWOULDBLOCK
#define SOCKET_ENFILE SOCENFILE
#define SOCKET_EMFILE SOCEMFILE
@@ -776,6 +778,7 @@ typedef off_t os_off_t;
#define closesocket(A) close(A)
#define SOCKET_EINTR EINTR
#define SOCKET_EAGAIN EAGAIN
+#define SOCKET_ETIMEDOUT SOCKET_EINTR
#define SOCKET_EWOULDBLOCK EWOULDBLOCK
#define SOCKET_ENFILE ENFILE
#define SOCKET_EMFILE EMFILE