[Scummvm-cvs-logs] SF.net SVN: scummvm: [32449] scummvm/trunk/engines/kyra/resource.cpp

lordhoto at users.sourceforge.net lordhoto at users.sourceforge.net
Sun Jun 1 01:26:42 CEST 2008


Revision: 32449
          http://scummvm.svn.sourceforge.net/scummvm/?rev=32449&view=rev
Author:   lordhoto
Date:     2008-05-31 16:26:41 -0700 (Sat, 31 May 2008)

Log Message:
-----------
Added error calls when out of memory while uncompressing HoF installer files.

Modified Paths:
--------------
    scummvm/trunk/engines/kyra/resource.cpp

Modified: scummvm/trunk/engines/kyra/resource.cpp
===================================================================
--- scummvm/trunk/engines/kyra/resource.cpp	2008-05-31 23:18:06 UTC (rev 32448)
+++ scummvm/trunk/engines/kyra/resource.cpp	2008-05-31 23:26:41 UTC (rev 32449)
@@ -1396,11 +1396,13 @@
 					tmpFile.seek(pos);
 
 					outbuffer = new uint8[outsize];
-					assert(outbuffer);
+					if (!outbuffer)
+						error("Out of memory: Can't uncompress installer files");
 
 					if (!inbuffer) {
 						inbuffer = new uint8[insize];
-						assert(inbuffer);
+						if (!inbuffer)
+							error("Out of memory: Can't uncompress installer files");
 					}
 
 					if ((pos + insize) > size) {


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