summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2008-04-12 04:20:34 +0000
committerEric Wong <normalperson@yhbt.net>2008-04-12 04:20:34 +0000
commitf4252ee795c330484b3be1f299c593c052a270be (patch)
tree9193a819ed8e0879d60cb056f87b04b2488ec6a8
parent00fbd7bb4b64d6078b79c1e35d5b1d3bb325a405 (diff)
missing num_channels check in previous patch
In the patch "special optimized case for 16bit stereo", the check for "num_channels==2" was missing. git-svn-id: https://svn.musicpd.org/mpd/trunk@7331 09075e82-0dd4-0310-85a5-a0d7c8717e4f
-rw-r--r--src/inputPlugins/flac_plugin.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/inputPlugins/flac_plugin.c b/src/inputPlugins/flac_plugin.c
index b52704959..75dc6aa2d 100644
--- a/src/inputPlugins/flac_plugin.c
+++ b/src/inputPlugins/flac_plugin.c
@@ -278,7 +278,7 @@ static FLAC__StreamDecoderWriteStatus flacWrite(const flac_decoder *dec,
if (num_samples > max_samples)
num_samples = max_samples;
- if (bytes_per_sample == 2)
+ if (num_channels == 2 && bytes_per_sample == 2)
flac_convert_stereo16(data->chunk + data->chunk_length,
buf, c_samp,
c_samp + num_samples);