Skip to content

Commit

Permalink
MDEV-24434 Assertion trx->in_rw_trx_list... in trx_sys_any_active_tra…
Browse files Browse the repository at this point in the history
…nsactions()

trx_sys_any_active_transactions(): Remove a bogus debug assertion.
In trx_commit_in_memory() and trx_erase_lists(), we will remove
the transaction from trx_sys->rw_trx_list and set the state to
TRX_STATE_COMMITTED_IN_MEMORY.
  • Loading branch information
dr-m committed Apr 12, 2021
1 parent 058d93d commit 75dd7a0
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions storage/innobase/trx/trx0sys.cc
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*****************************************************************************
Copyright (c) 1996, 2017, Oracle and/or its affiliates. All Rights Reserved.
Copyright (c) 2017, 2020, MariaDB Corporation.
Copyright (c) 2017, 2021, MariaDB Corporation.
This program is free software; you can redistribute it and/or modify it under
the terms of the GNU General Public License as published by the Free Software
Expand Down Expand Up @@ -997,11 +997,6 @@ trx_sys_any_active_transactions(void)
/* This may count some ACTIVE transactions twice,
both in rw_trx_list and mysql_trx_list. */
total_trx += trx->state == TRX_STATE_ACTIVE;
/* Any PREPARED or COMMITTED transactions must be
in rw_trx_list, so it suffices to count them there. */
ut_ad(trx->in_rw_trx_list
|| trx->state == TRX_STATE_NOT_STARTED
|| trx->state == TRX_STATE_ACTIVE);
trx_mutex_exit(trx);
}

Expand Down

0 comments on commit 75dd7a0

Please sign in to comment.