diff options
Diffstat (limited to 'engines/bladerunner/image.cpp')
-rw-r--r-- | engines/bladerunner/image.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/engines/bladerunner/image.cpp b/engines/bladerunner/image.cpp index 42070bc84a..157e443384 100644 --- a/engines/bladerunner/image.cpp +++ b/engines/bladerunner/image.cpp @@ -34,6 +34,10 @@ Image::Image(BladeRunnerEngine *vm) { } +Image::~Image() { + _surface.free(); +} + bool Image::open(const Common::String &name) { Common::SeekableReadStream *stream = _vm->getResourceStream(name); if (!stream) { @@ -67,6 +71,7 @@ bool Image::open(const Common::String &name) { _surface.init(width, height, 2*width, data, pixelFormat); delete[] buf; + delete stream; return true; } |