Commit 478d4021 authored by unknown's avatar unknown

Fix for bug#2021: Wron error message from the client


BitKeeper/etc/logging_ok:
  Logging to logging@openlogging.org accepted
parent cf2ecf37
...@@ -5,6 +5,7 @@ bar@bar.mysql.r18.ru ...@@ -5,6 +5,7 @@ bar@bar.mysql.r18.ru
bar@bar.udmsearch.izhnet.ru bar@bar.udmsearch.izhnet.ru
bell@sanja.is.com.ua bell@sanja.is.com.ua
bk@admin.bk bk@admin.bk
gluh@gluh.mysql.r18.ru
greg@gcw.ath.cx greg@gcw.ath.cx
greg@mysql.com greg@mysql.com
guilhem@mysql.com guilhem@mysql.com
......
...@@ -438,11 +438,7 @@ simple_command(MYSQL *mysql,enum enum_server_command command, const char *arg, ...@@ -438,11 +438,7 @@ simple_command(MYSQL *mysql,enum enum_server_command command, const char *arg,
if (mysql->net.vio == 0) if (mysql->net.vio == 0)
{ /* Do reconnect if possible */ { /* Do reconnect if possible */
if (mysql_reconnect(mysql)) if (mysql_reconnect(mysql))
{
net->last_errno=CR_SERVER_GONE_ERROR;
strmov(net->last_error,ER(net->last_errno));
goto end; goto end;
}
} }
if (mysql->status != MYSQL_STATUS_READY) if (mysql->status != MYSQL_STATUS_READY)
{ {
...@@ -1610,6 +1606,8 @@ static my_bool mysql_reconnect(MYSQL *mysql) ...@@ -1610,6 +1606,8 @@ static my_bool mysql_reconnect(MYSQL *mysql)
{ {
/* Allov reconnect next time */ /* Allov reconnect next time */
mysql->server_status&= ~SERVER_STATUS_IN_TRANS; mysql->server_status&= ~SERVER_STATUS_IN_TRANS;
mysql->net.last_errno= CR_SERVER_GONE_ERROR;
strmov(mysql->net.last_error, ER(mysql->net.last_errno));
DBUG_RETURN(1); DBUG_RETURN(1);
} }
mysql_init(&tmp_mysql); mysql_init(&tmp_mysql);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment