From 258d7ea535c2891bed4132e649c66fb86967a2a0 Mon Sep 17 00:00:00 2001 From: uruk Date: Mon, 28 Apr 2014 10:24:35 +0200 Subject: CGE2: Implement deinitialization properly. --- engines/cge2/cge2.cpp | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'engines/cge2/cge2.cpp') diff --git a/engines/cge2/cge2.cpp b/engines/cge2/cge2.cpp index 41b6249382..56393d20db 100644 --- a/engines/cge2/cge2.cpp +++ b/engines/cge2/cge2.cpp @@ -34,14 +34,14 @@ CGE2Engine::CGE2Engine(OSystem *syst, const ADGameDescription *gameDescription) _resman = nullptr; } -CGE2Engine::~CGE2Engine() { - delete _resman; -} - void CGE2Engine::init() { _resman = new ResourceManager(); } +void CGE2Engine::deinit() { + delete _resman; +} + bool CGE2Engine::hasFeature(EngineFeature f) const { return false; } @@ -66,6 +66,7 @@ Common::Error CGE2Engine::saveGameState(int slot, const Common::String &desc) { Common::Error CGE2Engine::run() { init(); warning("STUB: CGE2Engine::run()"); + deinit(); return Common::kNoError; } -- cgit v1.2.3