Fixing unnotified listener issues. The following usecases have been fixed:

Usecase 1 (ACTIVE -> PREPARING -> ROLLBACK -> ROLLED_BACK)

If rollback() have been called on transaction
while prepare() was in progress it might result
in prepare listener not to be notified when
transaction have been rolled back.

Usecase 2 (ACTIVE -> PREPARING -> PREPARED -> ROLLBACK -> ROLLED_BACK)

If both commit() & rollback() (in this exact order) have been called
on transaction while prepare() was in progress
it always resulted in commit listener to be lost
and not to be notified about transaction termination.

Usecase 3 (ACTIVE -> PREPARING -> PREPARED -> ROLLBACK -> ROLLED_BACK)

If both rollback() & commit() (in this exact order) have been called
on transaction while prepare() was in progress
it always resulted in rollback listener to be lost
and not to be notified about transaction termination.