mirror of
https://github.com/MariaDB/server.git
synced 2025-07-27 18:02:13 +03:00
Fixed MDEV-3890: Server crash inserting record on a temporary table after truncating it
The problem was that a temporary table was re-created as a non-temporary table. mysql-test/suite/maria/truncate.result: Added test cases mysql-test/suite/maria/truncate.test: Added test cases sql/sql_truncate.cc: Mark that table to be created is a temporary table storage/maria/ha_maria.cc: Ensure that temporary tables are not transactional.
This commit is contained in:
@ -263,6 +263,7 @@ static bool recreate_temporary_table(THD *thd, TABLE *table)
|
||||
DBUG_ENTER("recreate_temporary_table");
|
||||
|
||||
memset(&create_info, 0, sizeof(create_info));
|
||||
create_info.options|= HA_LEX_CREATE_TMP_TABLE;
|
||||
|
||||
table->file->info(HA_STATUS_AUTO | HA_STATUS_NO_LOCK);
|
||||
|
||||
|
Reference in New Issue
Block a user