summaryrefslogtreecommitdiff
path: root/indra/llcommon/llevents.h
diff options
context:
space:
mode:
authorNat Goodspeed <nat@lindenlab.com>2024-05-10 09:55:19 -0400
committerNat Goodspeed <nat@lindenlab.com>2024-05-10 09:55:19 -0400
commit271bc05b91772e5aedd834db116734b34f0108a1 (patch)
treeabb017c930974741bc8bf6f8b352c4124fc03ef6 /indra/llcommon/llevents.h
parent5060ccb1530ab576458aeff0d0b2b5dd24bc5880 (diff)
Fix latent access violation in ~LLEventPump() if LLEventPumps gone.
Instead of making LLEventPumps an LLHandleProvider, and storing an LLHandle<LLEventPumps> in each LLEventPump instance, just make ~LLEventPump() query LLEventPumps::instanceExists() before calling instance().
Diffstat (limited to 'indra/llcommon/llevents.h')
-rw-r--r--indra/llcommon/llevents.h16
1 files changed, 1 insertions, 15 deletions
diff --git a/indra/llcommon/llevents.h b/indra/llcommon/llevents.h
index 1fc0f23ecd..15d1d5035c 100644
--- a/indra/llcommon/llevents.h
+++ b/indra/llcommon/llevents.h
@@ -53,7 +53,6 @@
#include "llsingleton.h"
#include "lldependencies.h"
#include "llexception.h"
-#include "llhandle.h"
// hack for testing
#ifndef testable
@@ -213,15 +212,7 @@ class LLEventPump;
* LLEventPumps is a Singleton manager through which one typically accesses
* this subsystem.
*/
-// LLEventPumps isa LLHandleProvider only for (hopefully rare) long-lived
-// class objects that must refer to this class late in their lifespan, say in
-// the destructor. Specifically, the case that matters is a possible reference
-// after LLEventPumps::deleteSingleton(). (Lingering LLEventPump instances are
-// capable of this.) In that case, instead of calling LLEventPumps::instance()
-// again -- resurrecting the deleted LLSingleton -- store an
-// LLHandle<LLEventPumps> and test it before use.
-class LL_COMMON_API LLEventPumps: public LLSingleton<LLEventPumps>,
- public LLHandleProvider<LLEventPumps>
+class LL_COMMON_API LLEventPumps: public LLSingleton<LLEventPumps>
{
LLSINGLETON(LLEventPumps);
public:
@@ -582,12 +573,7 @@ private:
virtual void clear();
virtual void reset();
-
-
private:
- // must precede mName; see LLEventPump::LLEventPump()
- LLHandle<LLEventPumps> mRegistry;
-
std::string mName;
LLMutex mConnectionListMutex;