mirror of
https://github.com/MariaDB/server.git
synced 2025-08-08 11:22:35 +03:00
small cleanups
This commit is contained in:
0
mysql-test/r/lowercase_table4.result
Executable file → Normal file
0
mysql-test/r/lowercase_table4.result
Executable file → Normal file
0
mysql-test/suite/innodb/r/innodb_bug60196.result
Executable file → Normal file
0
mysql-test/suite/innodb/r/innodb_bug60196.result
Executable file → Normal file
0
mysql-test/suite/innodb/t/innodb_bug57904.test
Executable file → Normal file
0
mysql-test/suite/innodb/t/innodb_bug57904.test
Executable file → Normal file
0
mysql-test/suite/innodb/t/innodb_bug60196-master.opt
Executable file → Normal file
0
mysql-test/suite/innodb/t/innodb_bug60196-master.opt
Executable file → Normal file
0
mysql-test/suite/innodb/t/innodb_bug60196.test
Executable file → Normal file
0
mysql-test/suite/innodb/t/innodb_bug60196.test
Executable file → Normal file
0
mysql-test/t/lowercase_table4-master.opt
Executable file → Normal file
0
mysql-test/t/lowercase_table4-master.opt
Executable file → Normal file
0
mysql-test/t/lowercase_table4.test
Executable file → Normal file
0
mysql-test/t/lowercase_table4.test
Executable file → Normal file
0
mysql-test/t/range_vs_index_merge.test
Executable file → Normal file
0
mysql-test/t/range_vs_index_merge.test
Executable file → Normal file
0
mysql-test/t/range_vs_index_merge_innodb.test
Executable file → Normal file
0
mysql-test/t/range_vs_index_merge_innodb.test
Executable file → Normal file
13
sql/log.cc
13
sql/log.cc
@@ -2070,15 +2070,17 @@ static int binlog_savepoint_set(handlerton *hton, THD *thd, void *sv)
|
|||||||
binlog_trans_log_savepos(thd, (my_off_t*) sv);
|
binlog_trans_log_savepos(thd, (my_off_t*) sv);
|
||||||
/* Write it to the binary log */
|
/* Write it to the binary log */
|
||||||
|
|
||||||
String log_query;
|
char buf[1024];
|
||||||
if (log_query.append(STRING_WITH_LEN("SAVEPOINT ")) ||
|
String log_query(buf, sizeof(buf), &my_charset_bin);
|
||||||
|
if (log_query.copy(STRING_WITH_LEN("SAVEPOINT "), &my_charset_bin) ||
|
||||||
append_identifier(thd, &log_query,
|
append_identifier(thd, &log_query,
|
||||||
thd->lex->ident.str, thd->lex->ident.length))
|
thd->lex->ident.str, thd->lex->ident.length))
|
||||||
DBUG_RETURN(1);
|
DBUG_RETURN(1);
|
||||||
int errcode= query_error_code(thd, thd->killed == NOT_KILLED);
|
int errcode= query_error_code(thd, thd->killed == NOT_KILLED);
|
||||||
Query_log_event qinfo(thd, log_query.ptr(), log_query.length(),
|
Query_log_event qinfo(thd, log_query.ptr(), log_query.length(),
|
||||||
TRUE, FALSE, TRUE, errcode);
|
TRUE, FALSE, TRUE, errcode);
|
||||||
DBUG_RETURN(mysql_bin_log.write(&qinfo));
|
int ret= mysql_bin_log.write(&qinfo);
|
||||||
|
DBUG_RETURN(ret);
|
||||||
}
|
}
|
||||||
|
|
||||||
static int binlog_savepoint_rollback(handlerton *hton, THD *thd, void *sv)
|
static int binlog_savepoint_rollback(handlerton *hton, THD *thd, void *sv)
|
||||||
@@ -2093,8 +2095,9 @@ static int binlog_savepoint_rollback(handlerton *hton, THD *thd, void *sv)
|
|||||||
if (unlikely(trans_has_updated_non_trans_table(thd) ||
|
if (unlikely(trans_has_updated_non_trans_table(thd) ||
|
||||||
(thd->variables.option_bits & OPTION_KEEP_LOG)))
|
(thd->variables.option_bits & OPTION_KEEP_LOG)))
|
||||||
{
|
{
|
||||||
String log_query;
|
char buf[1024];
|
||||||
if (log_query.append(STRING_WITH_LEN("ROLLBACK TO ")) ||
|
String log_query(buf, sizeof(buf), &my_charset_bin);
|
||||||
|
if (log_query.copy(STRING_WITH_LEN("ROLLBACK TO "), &my_charset_bin) ||
|
||||||
append_identifier(thd, &log_query,
|
append_identifier(thd, &log_query,
|
||||||
thd->lex->ident.str, thd->lex->ident.length))
|
thd->lex->ident.str, thd->lex->ident.length))
|
||||||
DBUG_RETURN(1);
|
DBUG_RETURN(1);
|
||||||
|
@@ -741,14 +741,14 @@ static bool write_execute_load_query_log_event(THD *thd, sql_exchange* ex,
|
|||||||
List_iterator<Item> lu(thd->lex->update_list);
|
List_iterator<Item> lu(thd->lex->update_list);
|
||||||
List_iterator<Item> lv(thd->lex->value_list);
|
List_iterator<Item> lv(thd->lex->value_list);
|
||||||
|
|
||||||
query_str.append(" SET ");
|
query_str.append(STRING_WITH_LEN(" SET "));
|
||||||
n= 0;
|
n= 0;
|
||||||
|
|
||||||
while ((item= lu++))
|
while ((item= lu++))
|
||||||
{
|
{
|
||||||
val= lv++;
|
val= lv++;
|
||||||
if (n++)
|
if (n++)
|
||||||
query_str.append(", ");
|
query_str.append(STRING_WITH_LEN(", "));
|
||||||
append_identifier(thd, &query_str, item->name, strlen(item->name));
|
append_identifier(thd, &query_str, item->name, strlen(item->name));
|
||||||
query_str.append(val->name);
|
query_str.append(val->name);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user