diff options
Diffstat (limited to 'storage/spider/spd_db_conn.cc')
-rw-r--r-- | storage/spider/spd_db_conn.cc | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/storage/spider/spd_db_conn.cc b/storage/spider/spd_db_conn.cc index efb5e6d8c8c..13ff6c568de 100644 --- a/storage/spider/spd_db_conn.cc +++ b/storage/spider/spd_db_conn.cc @@ -119,7 +119,10 @@ int spider_db_connect( conn->net_write_timeout = spider_param_net_write_timeout(thd, share->net_write_timeouts[link_idx]); connect_retry_interval = spider_param_connect_retry_interval(thd); - connect_retry_count = spider_param_connect_retry_count(thd); + if (conn->disable_connect_retry) + connect_retry_count = 0; + else + connect_retry_count = spider_param_connect_retry_count(thd); } else { conn->connect_timeout = spider_param_connect_timeout(NULL, share->connect_timeouts[link_idx]); @@ -737,7 +740,8 @@ int spider_db_errorno( "to %ld: %d %s\n", l_time->tm_year + 1900, l_time->tm_mon + 1, l_time->tm_mday, l_time->tm_hour, l_time->tm_min, l_time->tm_sec, - current_thd->thread_id, error_num, conn->db_conn->get_error()); + (ulong) current_thd->thread_id, error_num, + conn->db_conn->get_error()); } if (!conn->mta_conn_mutex_unlock_later) { @@ -757,7 +761,8 @@ int spider_db_errorno( "to %ld: %d %s\n", l_time->tm_year + 1900, l_time->tm_mon + 1, l_time->tm_mday, l_time->tm_hour, l_time->tm_min, l_time->tm_sec, - current_thd->thread_id, error_num, conn->db_conn->get_error()); + (ulong) current_thd->thread_id, error_num, + conn->db_conn->get_error()); } if (!conn->mta_conn_mutex_unlock_later) { @@ -1368,7 +1373,7 @@ int spider_db_append_name_with_quote_str( for (name_end = name + length; name < name_end; name += length) { head_code = *name; - if (!(length = my_mbcharlen(system_charset_info, (uchar) head_code))) + if ((length= my_charlen(system_charset_info, name, name_end)) < 1) { my_message(ER_SPIDER_WRONG_CHARACTER_IN_NAME_NUM, ER_SPIDER_WRONG_CHARACTER_IN_NAME_STR, MYF(0)); |