diff options
author | Brad Linden <brad@lindenlab.com> | 2023-10-25 13:22:13 -0700 |
---|---|---|
committer | Brad Linden <brad@lindenlab.com> | 2023-10-25 16:12:13 -0700 |
commit | 673b3309dde153fdadf7559bd16a5bb6db4723a1 (patch) | |
tree | 726d5e38b016d1d5504c3024b0959cec00d6c9c1 /indra/llcommon/llerror.h | |
parent | 887226c7d2462306191126cc5bfc0de96e18ad42 (diff) | |
parent | e4d6a08941f9c4e81bda8ae14d481be5029353fd (diff) |
Merge remote-tracking branch 'origin/main' into DRTVWR-559
Diffstat (limited to 'indra/llcommon/llerror.h')
-rw-r--r-- | indra/llcommon/llerror.h | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/indra/llcommon/llerror.h b/indra/llcommon/llerror.h index f229b4964a..05dd88ee51 100644 --- a/indra/llcommon/llerror.h +++ b/indra/llcommon/llerror.h @@ -385,11 +385,9 @@ typedef LLError::NoClassInfo _LL_CLASS_TO_LOG; #define LL_NEWLINE '\n' // Use this only in LL_ERRS or in a place that LL_ERRS may not be used -#define LLERROR_CRASH \ -{ \ - int* make_me_crash = NULL;\ - *make_me_crash = 0; \ - exit(*make_me_crash); \ +#define LLERROR_CRASH \ +{ \ + crashdriver([](int* ptr){ *ptr = 0; exit(*ptr); }); \ } #define LL_ENDL \ @@ -491,4 +489,7 @@ LL_DEBUGS("SomeTag") performs the locking and map-searching ONCE, then caches the result in a static variable. */ +// used by LLERROR_CRASH +void crashdriver(void (*)(int*)); + #endif // LL_LLERROR_H |