summaryrefslogtreecommitdiff
path: root/sql/sql_lex.h
diff options
context:
space:
mode:
authorRucha Deodhar <rucha.deodhar@mariadb.com>2021-12-15 13:59:38 +0530
committerRucha Deodhar <rucha.deodhar@mariadb.com>2021-12-28 16:59:29 +0530
commitfad1d15326651a92895c799829ff66edc37fc20f (patch)
tree42ec5b7784677b579b7655afaaaa880af270551f /sql/sql_lex.h
parent4daf9d7c3ee05baf7643f3a866e6d3828e1bb93b (diff)
downloadmariadb-git-fad1d15326651a92895c799829ff66edc37fc20f.tar.gz
MDEV-25460: Assertion `!is_set() || (m_status == DA_OK_BULK && is_bulk_op())'
failed in Diagnostics_area::set_ok_status in my_ok from mysql_sql_stmt_prepare Analysis: Before PREPARE is executed, binlog_format is STATEMENT. This PREPARE had SET STATEMENT which sets binlog_format to ROW. Now after PREPARE is done we reset the binlog_format (back to STATEMENT). But we have temporary table, it doesn't let changing binlog_format=ROW to binlog_format=STATEMENT and gives error which goes unreported. This unreported error eventually causes assertion failure. Fix: Change return type for LEX::restore_set_statement_var() to bool and make it return error state.
Diffstat (limited to 'sql/sql_lex.h')
-rw-r--r--sql/sql_lex.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/sql/sql_lex.h b/sql/sql_lex.h
index bdf52e8ef7b..5585a95f67f 100644
--- a/sql/sql_lex.h
+++ b/sql/sql_lex.h
@@ -3094,7 +3094,7 @@ public:
int print_explain(select_result_sink *output, uint8 explain_flags,
bool is_analyze, bool *printed_anything);
- void restore_set_statement_var();
+ bool restore_set_statement_var();
void init_last_field(Column_definition *field, const char *name, CHARSET_INFO *cs);
void set_last_field_type(const Lex_field_type_st &type);