From d3f0b62348d55514f26d5727972138e3ed382e67 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Fri, 26 Feb 2016 18:55:06 +0100 Subject: [PATCH] pcm/export: another #ifdef ENABLE_DSD fix --- src/pcm/PcmExport.cxx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/pcm/PcmExport.cxx b/src/pcm/PcmExport.cxx index d1ecb20e3..4b9108cd1 100644 --- a/src/pcm/PcmExport.cxx +++ b/src/pcm/PcmExport.cxx @@ -36,7 +36,6 @@ PcmExport::Open(SampleFormat sample_format, unsigned _channels, bool _dop, bool _shift8, bool _pack, bool _reverse_endian) { assert(audio_valid_sample_format(sample_format)); - assert(!_dop || audio_valid_channel_count(_channels)); channels = _channels; alsa_channel_order = _alsa_channel_order @@ -44,12 +43,14 @@ PcmExport::Open(SampleFormat sample_format, unsigned _channels, : SampleFormat::UNDEFINED; #ifdef ENABLE_DSD + assert(!_dop || audio_valid_channel_count(_channels)); dop = _dop && sample_format == SampleFormat::DSD; if (dop) /* after the conversion to DoP, the DSD samples are stuffed inside fake 24 bit samples */ sample_format = SampleFormat::S24_P32; #else + (void)_channels; (void)_dop; #endif