From 37246b99f698f53194c3d60b471e190af79a45fe Mon Sep 17 00:00:00 2001 From: Andrey Kleshchev Date: Fri, 15 Sep 2023 01:22:27 +0300 Subject: SL-17135 Apr process creation crash looks like pool regularly gets corrupted, try using separate pool --- indra/llcommon/llapr.cpp | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'indra/llcommon/llapr.cpp') 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) -- cgit v1.2.3