aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authorTorbjörn Andersson2013-01-02 20:19:36 +0100
committerTorbjörn Andersson2013-01-02 20:19:36 +0100
commit5e304618bfa581742329c2d42e661f69755a6c91 (patch)
tree63b21bf98bacd3edf7dab238e6fcaed3b16163aa /engines
parentf4514069f33ba6a0ec72756a1aa3b2ae7b9ff6d1 (diff)
downloadscummvm-rg350-5e304618bfa581742329c2d42e661f69755a6c91.tar.gz
scummvm-rg350-5e304618bfa581742329c2d42e661f69755a6c91.tar.bz2
scummvm-rg350-5e304618bfa581742329c2d42e661f69755a6c91.zip
SCI: Fix potential (but probably very unlikely) memory leak
Spotted by Clang's code analyzer.
Diffstat (limited to 'engines')
-rw-r--r--engines/sci/decompressor.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/engines/sci/decompressor.cpp b/engines/sci/decompressor.cpp
index 82af6eca43..306825008d 100644
--- a/engines/sci/decompressor.cpp
+++ b/engines/sci/decompressor.cpp
@@ -590,6 +590,8 @@ void DecompressorLZW::reorderView(byte *src, byte *dest) {
if (celindex < cel_total) {
warning("View decompression generated too few (%d / %d) headers", celindex, cel_total);
+ free(cc_pos);
+ free(cc_lengths);
return;
}