aboutsummaryrefslogtreecommitdiffstats
path: root/src/decoder/ffmpeg_plugin.c
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2009-02-03 21:44:14 +0100
committerMax Kellermann <max@duempel.org>2009-02-03 22:51:38 +0100
commit81b6c0d77bc377a26906fe66fb11f51a6247be0a (patch)
tree8f19c08b544e024543ef787d0bc260c063653abc /src/decoder/ffmpeg_plugin.c
parenta7632b09e0f247bce1da742ac6c25fb52157f2a9 (diff)
downloadmpd-81b6c0d77bc377a26906fe66fb11f51a6247be0a.tar.gz
mpd-81b6c0d77bc377a26906fe66fb11f51a6247be0a.tar.xz
mpd-81b6c0d77bc377a26906fe66fb11f51a6247be0a.zip
ffmpeg: don't warn of empty packet output
If avcodec_decode_audio2() returns no output for an AVPacket, libavcodec may buffer some data, and return a larger chunk of output later. This patch disables a lot of bogus warnings.
Diffstat (limited to '')
-rw-r--r--src/decoder/ffmpeg_plugin.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/decoder/ffmpeg_plugin.c b/src/decoder/ffmpeg_plugin.c
index ba3355ee7..80cc00a5e 100644
--- a/src/decoder/ffmpeg_plugin.c
+++ b/src/decoder/ffmpeg_plugin.c
@@ -243,10 +243,9 @@ ffmpeg_send_packet(struct decoder *decoder, struct input_stream *is,
packet_data += len;
packet_size -= len;
- if (audio_size <= 0) {
- g_message("no audio frame\n");
+ if (audio_size <= 0)
continue;
- }
+
cmd = decoder_data(decoder, is,
audio_buf, audio_size,
position,