From 1b13e6be983c4befbdb2d78d050eb2da4753f03e Mon Sep 17 00:00:00 2001 From: Christoph Oelckers Date: Mon, 15 Sep 2014 11:24:48 +0200 Subject: [PATCH 1/2] -. fixed:S_LoadSound passed the wrong value for the lump size parameter to LoadSoundVoc. --- src/s_sound.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/s_sound.cpp b/src/s_sound.cpp index 32a245675..035b71c74 100644 --- a/src/s_sound.cpp +++ b/src/s_sound.cpp @@ -1321,7 +1321,7 @@ sfxinfo_t *S_LoadSound(sfxinfo_t *sfx) // If the sound is voc, use the custom loader. if (strncmp ((const char *)sfxstart, "Creative Voice File", 19) == 0) { - sfx->data = GSnd->LoadSoundVoc(sfxstart, len); + sfx->data = GSnd->LoadSoundVoc(sfxstart, size); } // If the sound is raw, just load it as such. // Otherwise, try the sound as DMX format. From 4be9a716361c119c4d81eb1571f58420ca333b75 Mon Sep 17 00:00:00 2001 From: Christoph Oelckers Date: Mon, 15 Sep 2014 11:32:40 +0200 Subject: [PATCH 2/2] - fixed: The VOC reader didn't advance the read index correctly. --- src/sound/i_sound.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/sound/i_sound.cpp b/src/sound/i_sound.cpp index c95b0221f..07cd43a4b 100644 --- a/src/sound/i_sound.cpp +++ b/src/sound/i_sound.cpp @@ -494,6 +494,7 @@ SoundHandle SoundRenderer::LoadSoundVoc(BYTE *sfxdata, int length) break; default: break; } + i += blocksize; } }