diff options
author | Luis Soares <luis.soares@oracle.com> | 2010-10-07 16:38:23 +0100 |
---|---|---|
committer | Luis Soares <luis.soares@oracle.com> | 2010-10-07 16:38:23 +0100 |
commit | cc15d2462cf0b32576010d1810960969cba48182 (patch) | |
tree | b35543a774425d8667083db479071a0b894beab7 /sql/sys_vars.cc | |
parent | d6ee2ecf90b8ad7110bef3aae9d447b8908f8cfb (diff) | |
download | mariadb-git-cc15d2462cf0b32576010d1810960969cba48182.tar.gz |
BUG#54144: ER_SLAVE_HEARTBEAT_VALUE_OUT_OF_RANGE is hard coded
The error message for ER_SLAVE_HEARTBEAT_VALUE_OUT_OF_RANGE was
hard coded. Additionally, the same error was used in three
separate error symptoms: 1. when heartbeat period exceeds the
value of slave_net_timeout, 2. when it is smaller than 1
milisecond and 3. when it was not in range, ie, either negative
or greater than the maximum allowed.
We fix this by splitting into three distinct errors and by
removing the message from the source code and moving it to the
errmsg-utf8.txt file.
Diffstat (limited to 'sql/sys_vars.cc')
-rw-r--r-- | sql/sys_vars.cc | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/sql/sys_vars.cc b/sql/sys_vars.cc index 69a01259fc0..b8b73bc0387 100644 --- a/sql/sys_vars.cc +++ b/sql/sys_vars.cc @@ -2943,11 +2943,8 @@ static bool fix_slave_net_timeout(sys_var *self, THD *thd, enum_var_type type) (active_mi? active_mi->heartbeat_period : 0.0))); if (active_mi && slave_net_timeout < active_mi->heartbeat_period) push_warning_printf(thd, MYSQL_ERROR::WARN_LEVEL_WARN, - ER_SLAVE_HEARTBEAT_VALUE_OUT_OF_RANGE, - "The current value for master_heartbeat_period" - " exceeds the new value of `slave_net_timeout' sec." - " A sensible value for the period should be" - " less than the timeout."); + ER_SLAVE_HEARTBEAT_VALUE_OUT_OF_RANGE_MAX, + ER(ER_SLAVE_HEARTBEAT_VALUE_OUT_OF_RANGE_MAX)); mysql_mutex_unlock(&LOCK_active_mi); return false; } |