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

Postfix (incorrect pools usage leading to memory leaks).

This commit is contained in:
hvlad 2021-07-05 23:33:24 +03:00
parent c6d1036585
commit 7d8179bfd4

View File

@ -1263,7 +1263,7 @@ void ExtEngineManager::closeAttachment(thread_db* tdbb, Attachment* attachment)
}
if (close)
{
{
if (engines.remove(accessor.current()->first)) // If engine has already been deleted - nothing to do
PluginManagerInterfacePtr()->releasePlugin(engine);
}
@ -1544,8 +1544,7 @@ void ExtEngineManager::makeTrigger(thread_db* tdbb, CompilerScratch* csb, Jrd::T
ContextManager<IExternalTrigger> ctxManager(tdbb, attInfo, attInfo->adminCharSet,
CallerName(obj_trigger, trg->name, userName));
///MemoryPool& pool = *tdbb->getDefaultPool();
MemoryPool& pool = *getDefaultMemoryPool();
MemoryPool& pool = *tdbb->getAttachment()->att_pool;
AutoPtr<RoutineMetadata> metadata(FB_NEW_POOL(pool) RoutineMetadata(pool));
metadata->name = trg->name;