Commit 67e2252b authored by Marko Mäkelä's avatar Marko Mäkelä

Simplify trx_state_eq()

parent 2c9e75cc
......@@ -48,19 +48,14 @@ trx_state_eq(
switch (trx->state) {
case TRX_STATE_PREPARED:
case TRX_STATE_PREPARED_RECOVERED:
case TRX_STATE_COMMITTED_IN_MEMORY:
ut_ad(!trx_is_autocommit_non_locking(trx));
return(trx->state == state);
case TRX_STATE_ACTIVE:
assert_trx_nonlocking_or_in_list(trx);
return(state == trx->state);
case TRX_STATE_COMMITTED_IN_MEMORY:
check_trx_state(trx);
return(state == trx->state);
case TRX_STATE_NOT_STARTED:
/* These states are not allowed for running transactions. */
ut_a(state == TRX_STATE_NOT_STARTED
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment