[Scummvm-cvs-logs] CVS: scummvm/sky sound.cpp,1.23,1.24

Max Horn fingolfin at users.sourceforge.net
Sun Jul 6 19:33:11 CEST 2003


Update of /cvsroot/scummvm/scummvm/sky
In directory sc8-pr-cvs1:/tmp/cvs-serv7643

Modified Files:
	sound.cpp 
Log Message:
another fix kudos to LavosSpawn

Index: sound.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/sky/sound.cpp,v
retrieving revision 1.23
retrieving revision 1.24
diff -u -d -r1.23 -r1.24
--- sound.cpp	7 Jul 2003 00:14:16 -0000	1.23
+++ sound.cpp	7 Jul 2003 02:32:20 -0000	1.24
@@ -1223,12 +1223,12 @@
 		return false;
 	}
 
-	uint32 speechSize = ((dataFileHeader *)speechData)->s_tot_size;
+	uint32 speechSize = ((dataFileHeader *)speechData)->s_tot_size - sizeof(dataFileHeader);
 	uint8 *playBuffer = (uint8 *)malloc(speechSize);
 	memcpy(playBuffer, speechData + sizeof(dataFileHeader), speechSize);
 
 	free(speechData);
 
-	_spSlot = _mixer->playRaw(&_ingameSpeech, playBuffer, speechSize - 64, 11025, SoundMixer::FLAG_UNSIGNED | SoundMixer::FLAG_AUTOFREE);
+	_spSlot = _mixer->playRaw(&_ingameSpeech, playBuffer, speechSize, 11025, SoundMixer::FLAG_UNSIGNED | SoundMixer::FLAG_AUTOFREE);
 	return true;
 }





More information about the Scummvm-git-logs mailing list