8
0
mirror of https://github.com/FirebirdSQL/firebird.git synced 2025-01-23 03:23:04 +01:00

Additional fix for bug CORE-5436 : [FB3 SC] Server hangs (under load test)

The case when main thread convert still not acquired lock when AST thread assert locks.
It leads to the error:  Fatal lock manager error: invalid lock id (0)
This commit is contained in:
hvlad 2018-09-17 21:00:08 +03:00
parent 7efe280e11
commit b6b7d6525c

View File

@ -394,6 +394,11 @@ bool LCK_convert_opt(thread_db* tdbb, Lock* lock, USHORT level)
if (dbb->dbb_ast_flags & DBB_assert_locks)
{
lock->lck_logical = old_level;
if (lock->lck_id == 0)
{
fb_assert(dbb->dbb_ast_flags & DBB_blocking);
return LCK_lock(tdbb, lock, level, LCK_NO_WAIT);
}
return LCK_convert(tdbb, lock, level, LCK_NO_WAIT);
}