mirror of
https://github.com/FirebirdSQL/firebird.git
synced 2025-01-23 04:03:04 +01:00
Fixed CORE-4999: Deadlock when trying to access database with invalid crypt key
This commit is contained in:
parent
d0768b2664
commit
ee96e00cb5
@ -426,7 +426,10 @@ void SDW_close()
|
||||
*
|
||||
**************************************/
|
||||
Database* dbb = GET_DBB();
|
||||
SyncLockGuard guard(&dbb->dbb_shadow_sync, SYNC_SHARED, "SDW_close");
|
||||
|
||||
Sync guard(&dbb->dbb_shadow_sync, "SDW_close");
|
||||
if (!dbb->dbb_shadow_sync.ourExclusiveLock())
|
||||
guard.lock(SYNC_SHARED);
|
||||
|
||||
for (Shadow* shadow = dbb->dbb_shadow; shadow; shadow = shadow->sdw_next)
|
||||
PIO_close(shadow->sdw_file);
|
||||
|
Loading…
Reference in New Issue
Block a user