Commit 09c0a961 authored by Adam Edward Barton's avatar Adam Edward Barton
Browse files

Merge branch 'AthenaIO_OutStream_MemFix' into 'master'

Manually delete addresses that are not added to the store to avoid memory leak.

See merge request !30511
parents 106605f0 90547787
......@@ -457,6 +457,9 @@ StatusCode AthenaOutputStreamTool::streamObjects(const DataObjectVec& dataObject
} else {
m_dataHeader->insert(proxy, addr, m_processTag);
}
if (m_store->storeID() == StoreID::EVENT_STORE) {
delete addr; addr = nullptr;
}
}
} else {
ATH_MSG_ERROR("Could not fill Object Refs for DataObject (clid/key):" << (*doIter)->clID() << " " << (*doIter)->name());
......@@ -479,6 +482,7 @@ StatusCode AthenaOutputStreamTool::streamObjects(const DataObjectVec& dataObject
} else {
m_dataHeader->insert(proxy, addr, m_processTag);
}
delete addr; addr = nullptr;
}
} else {
ATH_MSG_ERROR("Could not fill Object Refs for DataHeader");
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment