diff options
Diffstat (limited to 'audio/libaudiofile/patches/patch-ac')
-rw-r--r-- | audio/libaudiofile/patches/patch-ac | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/audio/libaudiofile/patches/patch-ac b/audio/libaudiofile/patches/patch-ac new file mode 100644 index 00000000000..c2ba61aceeb --- /dev/null +++ b/audio/libaudiofile/patches/patch-ac @@ -0,0 +1,24 @@ +$NetBSD: patch-ac,v 1.1 2009/01/21 15:19:27 drochner Exp $ + +--- libaudiofile/modules/msadpcm.c.orig 2004-03-06 07:39:23.000000000 +0100 ++++ libaudiofile/modules/msadpcm.c +@@ -129,8 +129,7 @@ static int ms_adpcm_decode_block (ms_adp + ms_adpcm_state *state[2]; + + /* Calculate the number of bytes needed for decoded data. */ +- outputLength = msadpcm->samplesPerBlock * sizeof (int16_t) * +- msadpcm->track->f.channelCount; ++ outputLength = msadpcm->samplesPerBlock * sizeof (int16_t); + + channelCount = msadpcm->track->f.channelCount; + +@@ -180,8 +179,7 @@ static int ms_adpcm_decode_block (ms_adp + The first two samples have already been 'decoded' in + the block header. + */ +- samplesRemaining = (msadpcm->samplesPerBlock - 2) * +- msadpcm->track->f.channelCount; ++ samplesRemaining = msadpcm->samplesPerBlock - (2 * channelCount); + + while (samplesRemaining > 0) + { |