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

Some (limited) protection from exceptions raised from inside JRD_shutdown_database

This commit is contained in:
Dmitry Yemanov 2020-07-08 12:33:06 +03:00
parent b5154afb6e
commit 4bc5133ebe

View File

@ -6667,11 +6667,21 @@ bool JRD_shutdown_database(Database* dbb, const unsigned flags)
fb_assert(!dbb->locked());
try
{
#ifdef SUPERSERVER_V2
TRA_header_write(tdbb, dbb, 0); // Update transaction info on header page.
#endif
if (flags & SHUT_DBB_RELEASE_POOLS)
TRA_update_counters(tdbb, dbb);
}
catch (const Exception&)
{
// Swallow exception raised from the physical I/O layer
// (e.g. due to database file being inaccessible).
// User attachment is already destroyed, so there's no chance
// this dbb can be cleaned up after raising an exception.
}
// Disable AST delivery as we're about to release all locks