Fixed a problem with wait/notify on transaction system, the cond_timedwait is not working as expected