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

Fixed #7402: Server crashes on startup error

(cherry picked from commit 3792ba4a7b)
This commit is contained in:
AlexPeshkoff 2022-11-30 20:21:09 +03:00
parent 37e338430f
commit 027d96c7c0

View File

@ -133,12 +133,15 @@ static void logSecurityDatabaseError(const char* path, ISC_STATUS* status)
if (fb_utils::containsErrorCode(status, isc_io_error))
return;
const int SHUTDOWN_TIMEOUT = 5000; // 5 sec
gds__log_status(path, status);
gds__put_error(path);
gds__print_status(status);
Firebird::Syslog::Record(Firebird::Syslog::Error, "Security database error");
gds__log_status(path, status);
if (isatty(2))
{
gds__put_error(path);
gds__print_status(status);
}
const int SHUTDOWN_TIMEOUT = 5000; // 5 sec
fb_shutdown(SHUTDOWN_TIMEOUT, fb_shutrsn_exit_called);
exit(STARTUP_ERROR);
}