From f1f5bdb5334997115fd18667eb8172f8dcfc6035 Mon Sep 17 00:00:00 2001 From: Yann Dirson Date: Sun, 20 Apr 2008 21:52:41 +0200 Subject: [PATCH] Add more assertions. --- src/ui.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/ui.cpp b/src/ui.cpp index c14745a..1a3c31d 100644 --- a/src/ui.cpp +++ b/src/ui.cpp @@ -27,7 +27,9 @@ class UIActionStateObserver : public ActionStateObserver { public: UIActionStateObserver(const UI* ui, const shared_ptr& controller) : m_ui(ui) - , m_controller(controller.get()) { } + , m_controller(controller.get()) { + Q_ASSERT(m_controller); + } virtual void notifyActionStateChange(GraphicalGame::ActionState state) { // check that the associated controller is active -- 2.11.4.GIT