summaryrefslogtreecommitdiff
path: root/sql/sql_binlog.cc
diff options
context:
space:
mode:
authorAndrei Elkin <andrei.elkin@mariadb.com>2019-02-07 15:57:15 +0200
committerAndrei Elkin <andrei.elkin@mariadb.com>2019-02-07 15:57:15 +0200
commit1efc19904aab326416cdadd00bc9e604bdb79df6 (patch)
treef093392f0cac776b0d2959d6142f7524961cd195 /sql/sql_binlog.cc
parent65c5ef9b495bac078ad2a502a75801c7cfe5b95a (diff)
downloadmariadb-git-1efc19904aab326416cdadd00bc9e604bdb79df6.tar.gz
merge fixes: sql_binlog.cc is done
Diffstat (limited to 'sql/sql_binlog.cc')
-rw-r--r--sql/sql_binlog.cc6
1 files changed, 3 insertions, 3 deletions
diff --git a/sql/sql_binlog.cc b/sql/sql_binlog.cc
index cc5acbc42d0..8801e9a806f 100644
--- a/sql/sql_binlog.cc
+++ b/sql/sql_binlog.cc
@@ -125,7 +125,7 @@ static int check_event_type(int type, Relay_log_info *rli)
int binlog_defragment(THD *thd)
{
user_var_entry *entry[2];
- LEX_STRING name[2]= { thd->lex->comment, thd->lex->ident };
+ LEX_CSTRING name[2]= { thd->lex->comment, thd->lex->ident };
/* compute the total size */
thd->lex->comment.str= NULL;
@@ -155,7 +155,7 @@ int binlog_defragment(THD *thd)
size_t gathered_length= 0;
for (uint k=0; k < 2; k++)
{
- memcpy(thd->lex->comment.str + gathered_length, entry[k]->value,
+ memcpy(const_cast<char*>(thd->lex->comment.str) + gathered_length, entry[k]->value,
entry[k]->length);
gathered_length += entry[k]->length;
update_hash(entry[k], true, NULL, 0, STRING_RESULT, &my_charset_bin, 0);
@@ -387,7 +387,7 @@ void mysql_client_binlog_statement(THD* thd)
end:
if (unlikely(is_fragmented))
- my_free(thd->lex->comment.str);
+ my_free(const_cast<char*>(thd->lex->comment.str));
thd->variables.option_bits= thd_options;
rgi->slave_close_thread_tables(thd);
my_free(buf);