1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-27 18:02:13 +03:00

Merge 10.4 into 10.5

This commit is contained in:
Marko Mäkelä
2019-12-16 07:47:17 +02:00
376 changed files with 6928 additions and 5364 deletions

View File

@ -487,9 +487,12 @@ int SEQUENCE::read_initial_values(TABLE *table)
Doing mysql_lock_tables() may have started a read only transaction.
If that happend, it's better that we commit it now, as a lot of
code assumes that there is no active stmt transaction directly after
open_tables()
open_tables().
But we also don't want to commit the stmt transaction while in a
substatement, see MDEV-15977.
*/
if (!has_active_transaction && !thd->transaction.stmt.is_empty())
if (!has_active_transaction && !thd->transaction.stmt.is_empty() &&
!thd->in_sub_stmt)
trans_commit_stmt(thd);
}
write_unlock(table);