Commit fd565205 authored by Rich Prohaska's avatar Rich Prohaska Committed by Yoni Fogel

#4855 merge 5.6 handlerton changes to main closes[t:4855]

git-svn-id: file:///svn/mysql/tokudb-engine/tokudb-engine@43279 c7de825b-a66e-492c-adef-691d508d4ae1
parent 05d0a5b0
This diff is collapsed.
......@@ -3,7 +3,11 @@
#endif
#define TOKU_INCLUDE_CHECKPOINT_LOCK 1
#if MYSQL_VERSION_ID < 50600
#define TOKU_INCLUDE_ROW_TYPE_COMPRESSION 1
#else
#define TOKU_INCLUDE_ROW_TYPE_COMPRESSION 0
#endif
#if !defined(HA_CLUSTERING)
#define HA_CLUSTERING 0
......
......@@ -597,7 +597,11 @@ inline uchar* pack_toku_blob(
u_int32_t length_bytes_in_tokudb, //number of bytes to use to encode the length in to_tokudb
u_int32_t length_bytes_in_mysql, //number of bytes used to encode the length in from_mysql
u_int32_t max_num_bytes,
#if MYSQL_VERSION_ID >= 50600
const CHARSET_INFO* charset
#else
CHARSET_INFO* charset
#endif
)
{
u_int32_t length = 0;
......@@ -749,7 +753,11 @@ inline uchar* pack_toku_varstring(
u_int32_t length_bytes_in_tokudb, //number of bytes to use to encode the length in to_tokudb
u_int32_t length_bytes_in_mysql, //number of bytes used to encode the length in from_mysql
u_int32_t max_num_bytes,
#if MYSQL_VERSION_ID >= 50600
const CHARSET_INFO *charset
#else
CHARSET_INFO* charset
#endif
)
{
u_int32_t length = 0;
......@@ -1374,7 +1382,7 @@ uchar* unpack_toku_key_field(
);
num_bytes_copied = new_pos - (from_tokudb + get_length_bytes_from_max(key_part_length));
assert(num_bytes_copied <= num_bytes);
bfill(to_mysql+num_bytes_copied, num_bytes - num_bytes_copied, field->charset()->pad_char);
memset(to_mysql+num_bytes_copied, field->charset()->pad_char, num_bytes - num_bytes_copied);
goto exit;
case (toku_type_varbinary):
case (toku_type_varstring):
......
......@@ -1021,8 +1021,8 @@ static int tokudb_discover(handlerton *hton, THD* thd, const char *db,
char path[FN_REFLEN + 1];
HA_METADATA_KEY curr_key = hatoku_frm_data;
DBT key, value;
bzero(&key, sizeof(key));
bzero(&value, sizeof(&value));
memset(&key, 0, sizeof(key));
memset(&value, 0, sizeof(&value));
error = db_env->txn_begin(db_env, 0, &txn, 0);
if (error) { goto cleanup; }
......@@ -1613,7 +1613,11 @@ static ST_FIELD_INFO tokudb_user_data_field_info[] = {
{NULL, 0, MYSQL_TYPE_NULL, 0, 0, NULL, SKIP_OPEN_TABLE}
};
#if MYSQL_VERSION_ID >= 50600
static int tokudb_user_data_fill_table(THD *thd, TABLE_LIST *tables, Item *cond) {
#else
static int tokudb_user_data_fill_table(THD *thd, TABLE_LIST *tables, COND *cond) {
#endif
int error;
uint64_t data_size;
TABLE *table = tables->table;
......@@ -1656,7 +1660,11 @@ static ST_FIELD_INFO tokudb_user_data_exact_field_info[] = {
{NULL, 0, MYSQL_TYPE_NULL, 0, 0, NULL, SKIP_OPEN_TABLE}
};
#if MYSQL_VERSION_ID >= 50600
static int tokudb_user_data_exact_fill_table(THD *thd, TABLE_LIST *tables, Item *cond) {
#else
static int tokudb_user_data_exact_fill_table(THD *thd, TABLE_LIST *tables, COND *cond) {
#endif
int error;
uint64_t data_size;
TABLE *table = tables->table;
......
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