mirror of
https://github.com/MariaDB/server.git
synced 2025-01-16 12:02:42 +01:00
fixed sleep
bug on reconnect sql/slave.cc: fixed sleep bug
This commit is contained in:
parent
6f2d56162b
commit
0889d8dc84
1 changed files with 3 additions and 2 deletions
|
@ -1481,9 +1481,10 @@ static int safe_reconnect(THD* thd, MYSQL* mysql, MASTER_INFO* mi)
|
|||
%s, last_errno=%d, retry in %d sec",
|
||||
mc_mysql_error(mysql), last_errno=mc_mysql_errno(mysql),
|
||||
mi->connect_retry);
|
||||
safe_sleep(thd, mi->connect_retry);
|
||||
}
|
||||
if (err_count++ == master_retry_count)
|
||||
safe_sleep(thd, mi->connect_retry);
|
||||
/* if master_retry_count is not set, keep trying until success */
|
||||
if (master_retry_count && err_count++ == master_retry_count)
|
||||
{
|
||||
slave_was_killed=1;
|
||||
break;
|
||||
|
|
Loading…
Reference in a new issue