Don't write over memory limit...

This commit is contained in:
def 2013-08-04 04:24:33 +02:00
parent 7b2578b517
commit da778f4e66

View file

@ -183,6 +183,9 @@ void CDemoRecorder::Write(int Type, const void *pData, int Size)
if(!m_File)
return;
if(Size > 64*1024)
return;
/* pad the data with 0 so we get an alignment of 4,
else the compression won't work and miss some bytes */
mem_copy(aBuffer2, pData, Size);