decoder: check audio_format_valid() in all decoders
Refuse to play audio formats which are not supported by MPD.
This commit is contained in:
@@ -405,6 +405,11 @@ aac_stream_decode(struct decoder *mpd_decoder, struct input_stream *inStream)
|
||||
.sample_rate = sample_rate,
|
||||
};
|
||||
|
||||
if (!audio_format_valid(&audio_format)) {
|
||||
g_warning("aac: invalid audio format\n");
|
||||
break;
|
||||
}
|
||||
|
||||
decoder_initialized(mpd_decoder, &audio_format,
|
||||
false, totalTime);
|
||||
initialized = true;
|
||||
|
||||
Reference in New Issue
Block a user