diff --git a/include/utils/Singleton.h b/include/utils/Singleton.h index 3b975b4c4..e1ee8eb06 100644 --- a/include/utils/Singleton.h +++ b/include/utils/Singleton.h @@ -37,6 +37,11 @@ public: } return *instance; } + + static bool hasInstance() { + Mutex::Autolock _l(sLock); + return sInstance != 0; + } protected: ~Singleton() { };