1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-09 22:24:09 +03:00

MDEV-16708: fixed assert firing in the method THD::reset_for_the_next_command

This commit is contained in:
Dmitry Shulga
2021-06-11 11:25:56 +07:00
committed by Sergei Golubchik
parent 994e3f40b5
commit fe78495053
2 changed files with 48 additions and 1 deletions

View File

@@ -5453,6 +5453,33 @@ public:
return (variables.old_behavior & OLD_MODE_UTF8_IS_UTF8MB3 ?
MY_UTF8_IS_UTF8MB3 : 0);
}
/**
Save current lex to the output parameter and reset it to point to
main_lex. This method is called from mysql_client_binlog_statement()
to temporary
@param[out] backup_lex original value of current lex
*/
void backup_and_reset_current_lex(LEX **backup_lex)
{
*backup_lex= lex;
lex= &main_lex;
}
/**
Restore current lex to its original value it had before calling the method
backup_and_reset_current_lex().
@param backup_lex original value of current lex
*/
void restore_current_lex(LEX *backup_lex)
{
lex= backup_lex;
}
};