aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authorWillem Jan Palenstijn2012-10-07 12:21:32 +0200
committerWillem Jan Palenstijn2012-10-07 12:27:14 +0200
commit8f754ced422eec38766e3d0dd50c82c6fe862f53 (patch)
tree0ee77438979707730b92d4b65938e1ad4d07feac /engines
parente8ad4df1fa93de65a7ed40c7e32a4b428e4fe7fa (diff)
downloadscummvm-rg350-8f754ced422eec38766e3d0dd50c82c6fe862f53.tar.gz
scummvm-rg350-8f754ced422eec38766e3d0dd50c82c6fe862f53.tar.bz2
scummvm-rg350-8f754ced422eec38766e3d0dd50c82c6fe862f53.zip
SCI: Flip assert
This way the assert is checking that the allocated buffer is large enough for the memcpy that follows it.
Diffstat (limited to 'engines')
-rw-r--r--engines/sci/engine/script.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/engines/sci/engine/script.cpp b/engines/sci/engine/script.cpp
index 037f4ab700..36d2841b07 100644
--- a/engines/sci/engine/script.cpp
+++ b/engines/sci/engine/script.cpp
@@ -144,7 +144,7 @@ void Script::load(int script_nr, ResourceManager *resMan) {
_heapStart = _buf + _scriptSize;
- assert(_bufSize - _scriptSize <= heap->size);
+ assert(_bufSize - _scriptSize >= heap->size);
memcpy(_heapStart, heap->data, heap->size);
}