summaryrefslogtreecommitdiff
path: root/audio/libaudiofile/patches/patch-ac
diff options
context:
space:
mode:
Diffstat (limited to 'audio/libaudiofile/patches/patch-ac')
-rw-r--r--audio/libaudiofile/patches/patch-ac9
1 files changed, 5 insertions, 4 deletions
diff --git a/audio/libaudiofile/patches/patch-ac b/audio/libaudiofile/patches/patch-ac
index c2ba61aceeb..643a56c0fa2 100644
--- a/audio/libaudiofile/patches/patch-ac
+++ b/audio/libaudiofile/patches/patch-ac
@@ -1,4 +1,4 @@
-$NetBSD: patch-ac,v 1.1 2009/01/21 15:19:27 drochner Exp $
+$NetBSD: patch-ac,v 1.2 2009/12/01 10:44:02 drochner Exp $
--- libaudiofile/modules/msadpcm.c.orig 2004-03-06 07:39:23.000000000 +0100
+++ libaudiofile/modules/msadpcm.c
@@ -8,17 +8,18 @@ $NetBSD: patch-ac,v 1.1 2009/01/21 15:19:27 drochner Exp $
/* 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);
++ outputLength = msadpcm->samplesPerBlock * sizeof (int16_t);
channelCount = msadpcm->track->f.channelCount;
-@@ -180,8 +179,7 @@ static int ms_adpcm_decode_block (ms_adp
+@@ -180,8 +179,8 @@ 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);
++ samplesRemaining = msadpcm->samplesPerBlock
++ - 2 * msadpcm->track->f.channelCount;
while (samplesRemaining > 0)
{