aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authorStrangerke2013-04-20 23:41:23 +0200
committerStrangerke2013-04-20 23:41:23 +0200
commit08b1002eb576090852e187d1de6f81383a29dab9 (patch)
treecff3e7196d826d614325ab75d49a2174228095b3 /engines
parent72101c66fac7f3d313e8a5702ba61fd5f47acc0b (diff)
downloadscummvm-rg350-08b1002eb576090852e187d1de6f81383a29dab9.tar.gz
scummvm-rg350-08b1002eb576090852e187d1de6f81383a29dab9.tar.bz2
scummvm-rg350-08b1002eb576090852e187d1de6f81383a29dab9.zip
HOPKINS: Fix check on index in LinesManager. CID 1004010
Diffstat (limited to 'engines')
-rw-r--r--engines/hopkins/lines.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/engines/hopkins/lines.cpp b/engines/hopkins/lines.cpp
index 6603708449..d0ca736430 100644
--- a/engines/hopkins/lines.cpp
+++ b/engines/hopkins/lines.cpp
@@ -2790,8 +2790,7 @@ void LinesManager::resetLines() {
// Remove Line
void LinesManager::removeLine(int idx) {
- if (idx > MAX_LINES)
- error("Attempting to add a line obstacle > MAX_LIGNE.");
+ assert (idx <= MAX_LINES);
_lineItem[idx]._lineData = (int16 *)_vm->_globals->freeMemory((byte *)_lineItem[idx]._lineData);
}