diff options
author | cmiller@zippy.cornsilk.net <> | 2007-01-31 16:26:12 -0500 |
---|---|---|
committer | cmiller@zippy.cornsilk.net <> | 2007-01-31 16:26:12 -0500 |
commit | a795b7097ff8303e772b8702669e035b7a6f946d (patch) | |
tree | feb686c0068723f2beea793f7b47d40c4afa8d34 /sql-common/client.c | |
parent | 85896c0af54829bcabd6256be08f0c9ec9952bd3 (diff) | |
parent | 777c5de911e89a275be5d8a40ff7b2a430e9cb7a (diff) | |
download | mariadb-git-a795b7097ff8303e772b8702669e035b7a6f946d.tar.gz |
Merge bk-internal.mysql.com:/home/bk/mysql-4.1-maint
into zippy.cornsilk.net:/home/cmiller/work/mysql/mysql-4.1-maint
Diffstat (limited to 'sql-common/client.c')
-rw-r--r-- | sql-common/client.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/sql-common/client.c b/sql-common/client.c index 87e22624dd9..431c1bdf418 100644 --- a/sql-common/client.c +++ b/sql-common/client.c @@ -1881,11 +1881,17 @@ CLI_MYSQL_REAL_CONNECT(MYSQL *mysql,const char *host, const char *user, goto error; } vio_keepalive(net->vio,TRUE); - /* Override local client variables */ + + /* If user set read_timeout, let it override the default */ if (mysql->options.read_timeout) net->read_timeout= mysql->options.read_timeout; + vio_timeout(net->vio, 0, net->read_timeout); + + /* If user set write_timeout, let it override the default */ if (mysql->options.write_timeout) net->write_timeout= mysql->options.write_timeout; + vio_timeout(net->vio, 1, net->write_timeout); + if (mysql->options.max_allowed_packet) net->max_packet_size= mysql->options.max_allowed_packet; |