diff --git a/Foundation/src/NotificationCenter.cpp b/Foundation/src/NotificationCenter.cpp index b714a84529..eb7e76cb2e 100644 --- a/Foundation/src/NotificationCenter.cpp +++ b/Foundation/src/NotificationCenter.cpp @@ -32,6 +32,10 @@ NotificationCenter::~NotificationCenter() try { Mutex::ScopedLock lock(_mutex); + for (auto& o: _observers) + o->disable(); + + _observers.clear(); } catch(...) {