Commit 6365e4db authored by Reimar Döffinger's avatar Reimar Döffinger Committed by Anton Khirnov

mp3enc: downgrade some errors in writing Xing frame to warnings

Also clarify the meaning of the log message.
parent 3b4bb19e
...@@ -110,14 +110,17 @@ static void mp3_write_xing(AVFormatContext *s) ...@@ -110,14 +110,17 @@ static void mp3_write_xing(AVFormatContext *s)
break; break;
} }
if (i == FF_ARRAY_ELEMS(avpriv_mpa_freq_tab)) { if (i == FF_ARRAY_ELEMS(avpriv_mpa_freq_tab)) {
av_log(s, AV_LOG_ERROR, "Unsupported sample rate.\n"); av_log(s, AV_LOG_WARNING, "Unsupported sample rate, not writing Xing "
"header.\n");
return; return;
} }
switch (codec->channels) { switch (codec->channels) {
case 1: channels = MPA_MONO; break; case 1: channels = MPA_MONO; break;
case 2: channels = MPA_STEREO; break; case 2: channels = MPA_STEREO; break;
default: av_log(s, AV_LOG_ERROR, "Unsupported number of channels.\n"); return; default: av_log(s, AV_LOG_WARNING, "Unsupported number of channels, "
"not writing Xing header.\n");
return;
} }
/* dummy MPEG audio header */ /* dummy MPEG audio header */
......
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