mirror of
https://github.com/scummvm/scummvm.git
synced 2026-06-20 05:45:29 +00:00
BLADERUNNER: Fix memory leaks in BladeRunnerEngine
This commit is contained in:
committed by
Eugene Sandulenko
parent
691d0f9888
commit
eefea240c7
@@ -42,17 +42,26 @@
|
||||
namespace BladeRunner {
|
||||
|
||||
BladeRunnerEngine::BladeRunnerEngine(OSystem *syst) : Engine(syst) {
|
||||
_gameInfo = nullptr;
|
||||
|
||||
_windowIsActive = true;
|
||||
_gameIsRunning = true;
|
||||
|
||||
_chapters = nullptr;
|
||||
_gameInfo = nullptr;
|
||||
_scene = new Scene(this);
|
||||
_script = new Script(this);
|
||||
_settings = new Settings(this);
|
||||
}
|
||||
|
||||
BladeRunnerEngine::~BladeRunnerEngine() {
|
||||
delete _settings;
|
||||
delete _script;
|
||||
delete _scene;
|
||||
delete _gameInfo;
|
||||
delete _chapters;
|
||||
|
||||
_surface1.free();
|
||||
}
|
||||
|
||||
bool BladeRunnerEngine::hasFeature(EngineFeature f) const {
|
||||
return f == kSupportsRTL;
|
||||
}
|
||||
|
||||
@@ -62,6 +62,7 @@ private:
|
||||
|
||||
public:
|
||||
BladeRunnerEngine(OSystem *syst);
|
||||
~BladeRunnerEngine();
|
||||
|
||||
bool hasFeature(EngineFeature f) const;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user