From cc8ed2979b14449f2dcf2b85daa7f13612d1dd00 Mon Sep 17 00:00:00 2001 From: Piotr Dziwinski Date: Sat, 11 May 2013 19:04:43 +0200 Subject: [PATCH] Fixed deleting of CObjectManager * fix in CApplication destructor * re-enabled unit tests --- src/app/app.cpp | 3 +++ test/unit/CMakeLists.txt | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/src/app/app.cpp b/src/app/app.cpp index 616caf90..190f6677 100644 --- a/src/app/app.cpp +++ b/src/app/app.cpp @@ -170,6 +170,9 @@ CApplication::~CApplication() delete m_private; m_private = nullptr; + delete m_objMan; + m_objMan = nullptr; + delete m_eventQueue; m_eventQueue = nullptr; diff --git a/test/unit/CMakeLists.txt b/test/unit/CMakeLists.txt index 5f9a588d..df92b9c2 100644 --- a/test/unit/CMakeLists.txt +++ b/test/unit/CMakeLists.txt @@ -228,7 +228,7 @@ ${LIBSNDFILE_LIBRARY} add_executable(colobot_ut ${COLOBOT_SOURCES} ${UT_SOURCES} ${OPENAL_SOURCES}) target_link_libraries(colobot_ut ${LIBS}) -#add_test(colobot_ut ./colobot_ut) +add_test(colobot_ut ./colobot_ut) # TODO: change the unit cases to independent automated tests to be included in colobot_ut add_subdirectory(common)