Skip to content

Commit

Permalink
fix build errors on windows environments
Browse files Browse the repository at this point in the history
  • Loading branch information
Kentoku committed Jun 5, 2020
1 parent 6c3180b commit 932baa9
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 11 deletions.
6 changes: 3 additions & 3 deletions storage/spider/ha_spider.cc
Original file line number Diff line number Diff line change
Expand Up @@ -9332,7 +9332,7 @@ ulong ha_spider::table_flags_for_partition()
{
DBUG_ENTER("ha_spider::table_flags_for_partition");
DBUG_PRINT("info",("spider this=%p", this));
DBUG_RETURN(
ulong flags =
#ifdef HA_PT_CALL_AT_ONCE_STORE_LOCK
HA_PT_CALL_AT_ONCE_STORE_LOCK |
#endif
Expand All @@ -9354,8 +9354,8 @@ ulong ha_spider::table_flags_for_partition()
#ifdef HA_PT_CALL_AT_ONCE_TOP_TABLE
HA_PT_CALL_AT_ONCE_TOP_TABLE |
#endif
0
);
0;
DBUG_RETURN(flags);
}

const char *ha_spider::index_type(
Expand Down
14 changes: 8 additions & 6 deletions storage/spider/spd_conn.cc
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
#include "probes_mysql.h"
#include "sql_class.h"
#include "sql_partition.h"
#include "sql_table.h"
#include "tztime.h"
#endif
#include "spd_err.h"
Expand Down Expand Up @@ -1923,15 +1924,16 @@ int spider_conn_queue_loop_check(
(uchar *) loop_check_buf, buf_sz - 1);
#endif
pthread_mutex_lock(&conn->loop_check_mutex);
if (unlikely(
#ifdef SPIDER_HAS_HASH_VALUE_TYPE
!(lcptr = (SPIDER_CONN_LOOP_CHECK *)
my_hash_search_using_hash_value(&conn->loop_checked, hash_value,
(uchar *) loop_check_buf, buf_sz - 1)) ||
lcptr = (SPIDER_CONN_LOOP_CHECK *)
my_hash_search_using_hash_value(&conn->loop_checked, hash_value,
(uchar *) loop_check_buf, buf_sz - 1);
#else
!(lcptr = (SPIDER_CONN_LOOP_CHECK *) my_hash_search(
&conn->loop_checked, (uchar *) loop_check_buf, buf_sz - 1)) ||
lcptr = (SPIDER_CONN_LOOP_CHECK *) my_hash_search(
&conn->loop_checked, (uchar *) loop_check_buf, buf_sz - 1);
#endif
if (unlikely(
!lcptr ||
(
!lcptr->flag &&
(
Expand Down
5 changes: 3 additions & 2 deletions storage/spider/spd_db_mysql.cc
Original file line number Diff line number Diff line change
Expand Up @@ -2359,8 +2359,9 @@ int spider_db_mbase::print_warnings(
DBUG_PRINT("info",("spider row[2]=%s", row[2]));
longlong res_num =
(longlong) my_strtoll10(row[1], (char**) NULL, &error_num);
my_printf_error(res_num, row[2], MYF(0));
error_num = res_num;
DBUG_PRINT("info",("spider res_num=%lld", res_num));
my_printf_error((int) res_num, row[2], MYF(0));
error_num = (int) res_num;
row = mysql_fetch_row(res);
}
}
Expand Down

0 comments on commit 932baa9

Please sign in to comment.