summaryrefslogtreecommitdiff
path: root/indra/llcommon/llapr.cpp
diff options
context:
space:
mode:
authorAndrey Kleshchev <andreykproductengine@lindenlab.com>2023-09-15 01:22:27 +0300
committerakleshchev <117672381+akleshchev@users.noreply.github.com>2023-10-03 21:14:34 +0300
commitaf9fe170894f16f48e1f99c500648b50fbbf5655 (patch)
treed7450badaca330b86d090ba766f5058a3b36824a /indra/llcommon/llapr.cpp
parent35c3b391674f3a8ab64c383845579f19c2865caa (diff)
SL-17135 Apr process creation crash
looks like pool regularly gets corrupted, try using separate pool
Diffstat (limited to 'indra/llcommon/llapr.cpp')
-rw-r--r--indra/llcommon/llapr.cpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/indra/llcommon/llapr.cpp b/indra/llcommon/llapr.cpp
index 435531f86f..69466df2d1 100644
--- a/indra/llcommon/llapr.cpp
+++ b/indra/llcommon/llapr.cpp
@@ -38,6 +38,12 @@ const S32 FULL_VOLATILE_APR_POOL = 1024 ; //number of references to LLVolatileAP
bool gAPRInitialized = false;
+int abortfunc(int retcode)
+{
+ LL_WARNS("APR") << "Allocation failure in apr pool with code " << (S32)retcode << LL_ENDL;
+ return 0;
+}
+
void ll_init_apr()
{
// Initialize APR and create the global pool
@@ -45,7 +51,7 @@ void ll_init_apr()
if (!gAPRPoolp)
{
- apr_pool_create(&gAPRPoolp, NULL);
+ apr_pool_create_ex(&gAPRPoolp, NULL, abortfunc, NULL);
}
if(!LLAPRFile::sAPRFilePoolp)