[Scummvm-cvs-logs] scummvm master -> 3e90a83aa438d747ff8416d91c6192d453e5e1bd
wjp
wjp at usecode.org
Sun Feb 7 00:01:49 CET 2016
This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
3e90a83aa4 COMMON: Fix memory leak in decompressDCL
Commit: 3e90a83aa438d747ff8416d91c6192d453e5e1bd
https://github.com/scummvm/scummvm/commit/3e90a83aa438d747ff8416d91c6192d453e5e1bd
Author: Willem Jan Palenstijn (wjp at usecode.org)
Date: 2016-02-07T00:00:13+01:00
Commit Message:
COMMON: Fix memory leak in decompressDCL
Changed paths:
common/dcl.cpp
diff --git a/common/dcl.cpp b/common/dcl.cpp
index 66dfb76..75a533a 100644
--- a/common/dcl.cpp
+++ b/common/dcl.cpp
@@ -470,7 +470,7 @@ bool decompressDCL(ReadStream *src, byte *dest, uint32 packedSize, uint32 unpack
// Read source into memory
src->read(sourceBufferPtr, packedSize);
- Common::MemoryReadStream *sourceStream = new MemoryReadStream(sourceBufferPtr, packedSize, DisposeAfterUse::NO);
+ Common::MemoryReadStream *sourceStream = new MemoryReadStream(sourceBufferPtr, packedSize, DisposeAfterUse::YES);
Common::MemoryWriteStream *targetStream = new MemoryWriteStream(dest, unpackedSize);
success = dcl.unpack(sourceStream, targetStream, unpackedSize, true);
More information about the Scummvm-git-logs
mailing list