[Scummvm-cvs-logs] SF.net SVN: scummvm:[53609] scummvm/trunk/engines/sword25/sword25.cpp

fingolfin at users.sourceforge.net fingolfin at users.sourceforge.net
Tue Oct 19 11:44:29 CEST 2010


Revision: 53609
          http://scummvm.svn.sourceforge.net/scummvm/?rev=53609&view=rev
Author:   fingolfin
Date:     2010-10-19 09:44:29 +0000 (Tue, 19 Oct 2010)

Log Message:
-----------
SWORD25: Destroy singletons upon engine exit (untested, may lead to crash upon exit)

Modified Paths:
--------------
    scummvm/trunk/engines/sword25/sword25.cpp

Modified: scummvm/trunk/engines/sword25/sword25.cpp
===================================================================
--- scummvm/trunk/engines/sword25/sword25.cpp	2010-10-19 09:44:13 UTC (rev 53608)
+++ scummvm/trunk/engines/sword25/sword25.cpp	2010-10-19 09:44:29 UTC (rev 53609)
@@ -42,6 +42,10 @@
 #include "sword25/package/packagemanager.h"
 #include "sword25/script/script.h"
 
+#include "sword25/gfx/animationtemplateregistry.h"	// Needed so we can destroy the singleton
+#include "sword25/gfx/renderobjectregistry.h"		// Needed so we can destroy the singleton
+#include "sword25/math/regionregistry.h"			// Needed so we can destroy the singleton
+
 namespace Sword25 {
 
 #define BS_LOG_PREFIX "MAIN"
@@ -140,6 +144,10 @@
 	// The kernel is shutdown, and un-initialises all subsystems
 	Kernel::DeleteInstance();
 
+	AnimationTemplateRegistry::destroy();
+	RenderObjectRegistry::destroy();
+	RegionRegistry::destroy();
+
 	// Free the log file if it was used
 	BS_Log::_CloseLog();
 


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.




More information about the Scummvm-git-logs mailing list