1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-29 05:21:33 +03:00

MDEV-22445 Crash on HANDLER READ NEXT after XA PREPARE

The assertion is absolutely correct since no data access is possible after
XA PREPARE.

The check is added in mysql_ha_read.
This commit is contained in:
Nikita Malyavin
2021-10-07 17:02:26 +03:00
parent 1811fd51fb
commit caebe151c1
3 changed files with 35 additions and 0 deletions

View File

@ -697,6 +697,9 @@ retry:
if (!(handler= mysql_ha_find_handler(thd, tables->alias)))
goto err0;
if (thd->transaction.xid_state.check_has_uncommitted_xa())
goto err0;
table= handler->table;
tables->table= table; // This is used by fix_fields
table->pos_in_table_list= tables;