Skip to content

Commit

Permalink
MDEV-6247 post-fix: Re-enable some debug assertions
Browse files Browse the repository at this point in the history
These assertions were disabled in MariaDB 10.1.1 in
commit df4dd59
with a bogus comment referring to the function wsrep_fake_trx_id()
that was introduced in the very same commit.
  • Loading branch information
dr-m committed Dec 21, 2017
1 parent 5f896b3 commit 1cf2896
Show file tree
Hide file tree
Showing 4 changed files with 0 additions and 16 deletions.
3 changes: 0 additions & 3 deletions storage/innobase/include/trx0sys.ic
Original file line number Diff line number Diff line change
Expand Up @@ -445,10 +445,7 @@ trx_id_t
trx_sys_get_new_trx_id(void)
/*========================*/
{
#ifndef WITH_WSREP
/* wsrep_fake_trx_id violates this assert */
ut_ad(mutex_own(&trx_sys->mutex));
#endif /* WITH_WSREP */

/* VERY important: after the database is started, max_trx_id value is
divisible by TRX_SYS_TRX_ID_WRITE_MARGIN, and the following if
Expand Down
5 changes: 0 additions & 5 deletions storage/innobase/trx/trx0sys.cc
Original file line number Diff line number Diff line change
Expand Up @@ -180,12 +180,7 @@ trx_sys_flush_max_trx_id(void)
mtr_t mtr;
trx_sysf_t* sys_header;

#ifndef WITH_WSREP
/* wsrep_fake_trx_id violates this assert
* Copied from trx_sys_get_new_trx_id
*/
ut_ad(mutex_own(&trx_sys->mutex));
#endif /* WITH_WSREP */

if (!srv_read_only_mode) {
mtr_start(&mtr);
Expand Down
3 changes: 0 additions & 3 deletions storage/xtradb/include/trx0sys.ic
Original file line number Diff line number Diff line change
Expand Up @@ -474,10 +474,7 @@ trx_id_t
trx_sys_get_new_trx_id(void)
/*========================*/
{
#ifndef WITH_WSREP
/* wsrep_fake_trx_id violates this assert */
ut_ad(mutex_own(&trx_sys->mutex));
#endif /* WITH_WSREP */

/* VERY important: after the database is started, max_trx_id value is
divisible by TRX_SYS_TRX_ID_WRITE_MARGIN, and the following if
Expand Down
5 changes: 0 additions & 5 deletions storage/xtradb/trx/trx0sys.cc
Original file line number Diff line number Diff line change
Expand Up @@ -184,12 +184,7 @@ trx_sys_flush_max_trx_id(void)
mtr_t mtr;
trx_sysf_t* sys_header;

#ifndef WITH_WSREP
/* wsrep_fake_trx_id violates this assert
* Copied from trx_sys_get_new_trx_id
*/
ut_ad(mutex_own(&trx_sys->mutex));
#endif /* WITH_WSREP */

if (!srv_read_only_mode) {
mtr_start(&mtr);
Expand Down

0 comments on commit 1cf2896

Please sign in to comment.