summaryrefslogtreecommitdiff
path: root/libmysqld
diff options
context:
space:
mode:
authorunknown <kroki/tomash@moonlight.intranet>2006-09-18 22:02:06 +0400
committerunknown <kroki/tomash@moonlight.intranet>2006-09-18 22:02:06 +0400
commit0b2a28f5cf69237f501b075dd3cfde318768fce8 (patch)
tree239a22917b95abda36af68025cb1329170dc0517 /libmysqld
parentdcb665900136fb4015589680c612add8abf1deca (diff)
downloadmariadb-git-0b2a28f5cf69237f501b075dd3cfde318768fce8.tar.gz
BUG#9678: Client library hangs after network communication failure
(back-port to 4.0) Socket timeouts in client library were used only on Windows. Additionally, in 4.0 write operations erroneously set read timeout. The solution is to use socket timeouts in client library on all systems were they are supported, and to differentiate between read and write timeouts. No test case is provided because it is impossible to simulate network failure in current test suite. include/violite.h: Add argument to vio_timeout() to determine which timeout should be set: for read (false) or for write (true). libmysqld/lib_vio.c: Add argument to vio_timeout() to determine which timeout should be set: for read (false) or for write (true). sql/net_serv.cc: Add argument to vio_timeout() to determine which timeout should be set: for read (false) or for write (true). vio/viosocket.c: Add argument to vio_timeout() to determine which timeout should be set: for read (false) or for write (true). Implement socket timeouts on POSIX systems.
Diffstat (limited to 'libmysqld')
-rw-r--r--libmysqld/lib_vio.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/libmysqld/lib_vio.c b/libmysqld/lib_vio.c
index 0f5f7fda550..883080e8b92 100644
--- a/libmysqld/lib_vio.c
+++ b/libmysqld/lib_vio.c
@@ -229,6 +229,7 @@ my_bool vio_poll_read(Vio *vio,uint timeout)
void vio_timeout(Vio *vio __attribute__((unused)),
+ uint which __attribute__((unused)),
uint timeout __attribute__((unused)))
{
}