Commit a012b253 authored by Max Kellermann's avatar Max Kellermann

filter/convert: fix no-op check

Commit 3a212412 changed the meaning of out_audio_format, but I forgot to apply this to ConvertFilter::FilterPCM(). See https://bugs.musicpd.org/view.php?id=4551
parent 46e8b137
......@@ -110,7 +110,7 @@ ConvertFilter::~ConvertFilter()
{
assert(in_audio_format.IsValid());
if (out_audio_format.IsValid())
if (out_audio_format != in_audio_format)
state.Close();
}
......@@ -119,7 +119,7 @@ ConvertFilter::FilterPCM(ConstBuffer<void> src, Error &error)
{
assert(in_audio_format.IsValid());
if (!out_audio_format.IsValid())
if (out_audio_format == in_audio_format)
/* optimized special case: no-op */
return src;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment