[Scummvm-cvs-logs] SF.net SVN: scummvm: [32089] scummvm/trunk/engines/made/scriptfuncs_lgop2. cpp
thebluegr at users.sourceforge.net
thebluegr at users.sourceforge.net
Tue May 13 18:12:40 CEST 2008
Revision: 32089
http://scummvm.svn.sourceforge.net/scummvm/?rev=32089&view=rev
Author: thebluegr
Date: 2008-05-13 09:12:37 -0700 (Tue, 13 May 2008)
Log Message:
-----------
Added a sanity check to o1_LOADCURSOR to prevent LGoP2 from crashing when the save/load menu is opened during character selection
Modified Paths:
--------------
scummvm/trunk/engines/made/scriptfuncs_lgop2.cpp
Modified: scummvm/trunk/engines/made/scriptfuncs_lgop2.cpp
===================================================================
--- scummvm/trunk/engines/made/scriptfuncs_lgop2.cpp 2008-05-13 16:09:57 UTC (rev 32088)
+++ scummvm/trunk/engines/made/scriptfuncs_lgop2.cpp 2008-05-13 16:12:37 UTC (rev 32089)
@@ -443,6 +443,9 @@
int16 ScriptFunctionsLgop2::o1_LOADCURSOR(int16 argc, int16 *argv) {
PictureResource *flex = _vm->_res->getPicture(argv[2]);
+ if (!flex)
+ return 0;
+
Graphics::Surface *surf = flex->getPicture();
CursorMan.replaceCursor((const byte *)surf->pixels, surf->w, surf->h, argv[1], argv[0], 0);
CursorMan.showMouse(true);
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the Scummvm-git-logs
mailing list