[Scummvm-cvs-logs] SF.net SVN: scummvm: [23184] scummvm/trunk/sound/audiostream.cpp

anotherguest at users.sourceforge.net anotherguest at users.sourceforge.net
Mon Jun 19 23:08:39 CEST 2006


Revision: 23184
Author:   anotherguest
Date:     2006-06-19 14:08:34 -0700 (Mon, 19 Jun 2006)
ViewCVS:  http://svn.sourceforge.net/scummvm/?rev=23184&view=rev

Log Message:
-----------
Added assert to audiostream allocation since failure causes serious problems

Modified Paths:
--------------
    scummvm/trunk/sound/audiostream.cpp
Modified: scummvm/trunk/sound/audiostream.cpp
===================================================================
--- scummvm/trunk/sound/audiostream.cpp	2006-06-19 21:07:37 UTC (rev 23183)
+++ scummvm/trunk/sound/audiostream.cpp	2006-06-19 21:08:34 UTC (rev 23184)
@@ -261,6 +261,8 @@
 		assert((bufferSize & 1) == 0);
 
 	_bufferStart = (byte *)malloc(bufferSize);
+	assert(_bufferStart != NULL);
+
 	_pos = _end = _bufferStart;
 	_bufferEnd = _bufferStart + bufferSize;
 }


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