summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoryexo <yexo@openttd.org>2009-06-07 15:54:37 +0000
committeryexo <yexo@openttd.org>2009-06-07 15:54:37 +0000
commit9db1f5925c3512cf8bbd3c7bccd12381d07ebd1f (patch)
treee97b9c7c65c37e2120a9d407b975fb6cd8349103
parente3ba9c487f98acf50922cda8ae7e7c1e118628e2 (diff)
downloadopenttd-9db1f5925c3512cf8bbd3c7bccd12381d07ebd1f.tar.xz
(svn r16532) -Fix [Squirrel]: Don't copy an object when we just checked that the pointer to it is NULL
-rw-r--r--src/3rdparty/squirrel/squirrel/sqvm.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/3rdparty/squirrel/squirrel/sqvm.cpp b/src/3rdparty/squirrel/squirrel/sqvm.cpp
index fb3785787..10edc5970 100644
--- a/src/3rdparty/squirrel/squirrel/sqvm.cpp
+++ b/src/3rdparty/squirrel/squirrel/sqvm.cpp
@@ -938,7 +938,7 @@ common_call:
traps -= ci->_etraps;
if(sarg1 != MAX_FUNC_STACKSIZE) STK(arg1) = temp_reg;
}
- else { Raise_Error(_SC("trying to yield a '%s',only genenerator can be yielded"), GetTypeName(ci->_generator)); SQ_THROW();}
+ else { Raise_Error(_SC("trying to yield a '%s',only genenerator can be yielded"), GetTypeName(ci->_closure)); SQ_THROW();}
if(Return(arg0, arg1, temp_reg)){
assert(traps == 0);
outres = temp_reg;