aboutsummaryrefslogtreecommitdiffstats
path: root/src/encoder/plugins
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2015-10-27 11:05:47 +0100
committerMax Kellermann <max@duempel.org>2015-10-27 11:05:47 +0100
commit94f850a5885c89e5255948f9274aaaa4197bc52b (patch)
tree5348c92cb0ed9a3dc409be922abac07eee4438de /src/encoder/plugins
parent3882c114505ea39e3707f27d91eb8ef363a8895b (diff)
parentdb9997a1068e00c5f78d4bb9834ce5a13e7b7a3b (diff)
downloadmpd-94f850a5885c89e5255948f9274aaaa4197bc52b.tar.gz
mpd-94f850a5885c89e5255948f9274aaaa4197bc52b.tar.xz
mpd-94f850a5885c89e5255948f9274aaaa4197bc52b.zip
Merge tag 'v0.19.11'
Diffstat (limited to 'src/encoder/plugins')
-rw-r--r--src/encoder/plugins/FlacEncoderPlugin.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/encoder/plugins/FlacEncoderPlugin.cxx b/src/encoder/plugins/FlacEncoderPlugin.cxx
index afeef3b84..86a3588df 100644
--- a/src/encoder/plugins/FlacEncoderPlugin.cxx
+++ b/src/encoder/plugins/FlacEncoderPlugin.cxx
@@ -157,8 +157,6 @@ flac_encoder_open(Encoder *_encoder, AudioFormat &audio_format, Error &error)
struct flac_encoder *encoder = (struct flac_encoder *)_encoder;
unsigned bits_per_sample;
- encoder->audio_format = audio_format;
-
/* FIXME: flac should support 32bit as well */
switch (audio_format.format) {
case SampleFormat::S8:
@@ -178,6 +176,8 @@ flac_encoder_open(Encoder *_encoder, AudioFormat &audio_format, Error &error)
audio_format.format = SampleFormat::S24_P32;
}
+ encoder->audio_format = audio_format;
+
/* allocate the encoder */
encoder->fse = FLAC__stream_encoder_new();
if (encoder->fse == nullptr) {