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

restored old behavior in OOM conditions - thanks to Claudio

This commit is contained in:
alexpeshkoff 2008-09-08 13:26:47 +00:00
parent 1a042dcd4c
commit 41488cd241

View File

@ -572,10 +572,15 @@ void REMOTE_save_status_strings( ISC_STATUS* vector)
if (!attachFailures)
{
attachFailures = FB_NEW(*getDefaultMemoryPool()) Firebird::CircularStringsBuffer<ATTACH_FAILURE_SPACE>;
/* FREE: freed by exit handler cleanup_memory() */
if (!attachFailures) /* NOMEM: don't bother trying to copy */
try
{
attachFailures = FB_NEW(*getDefaultMemoryPool()) Firebird::CircularStringsBuffer<ATTACH_FAILURE_SPACE>;
/* FREE: freed by exit handler cleanup_memory() */
}
catch (const Firebird::BadAlloc&) /* NOMEM: don't bother trying to copy */
{
return;
}
gds__register_cleanup(cleanup_memory, 0);
}