diff options
-rw-r--r-- | engines/gnap/gamesys.cpp | 3 | ||||
-rw-r--r-- | engines/gnap/gnap.cpp | 1 |
2 files changed, 4 insertions, 0 deletions
diff --git a/engines/gnap/gamesys.cpp b/engines/gnap/gamesys.cpp index 26af3fb8ab..4b18fd14a3 100644 --- a/engines/gnap/gamesys.cpp +++ b/engines/gnap/gamesys.cpp @@ -65,6 +65,9 @@ GameSys::GameSys(GnapEngine *vm) : _vm(vm) { } GameSys::~GameSys() { + if (_frontSurface) + _frontSurface->free(); + delete _frontSurface; } void GameSys::insertSequence(int sequenceId, int id, int sequenceId2, int id2, int flags, int totalDuration, int16 x, int16 y) { diff --git a/engines/gnap/gnap.cpp b/engines/gnap/gnap.cpp index 8acc3eedae..7523cd4de5 100644 --- a/engines/gnap/gnap.cpp +++ b/engines/gnap/gnap.cpp @@ -157,6 +157,7 @@ Common::Error GnapEngine::run() { _font = Graphics::loadTTFFont(*stream, 24); if (!_font) warning("Unable to load font"); + delete stream; #else _font = nullptr; #endif |