driver/audiodec/ffmpegdec: reopen codec on error (experimental fix)

This commit is contained in:
martii
2013-10-13 16:18:31 +02:00
committed by [CST] Focus
parent 52620ccc91
commit c11aa70f28

View File

@@ -224,6 +224,8 @@ CBaseDec::RetCode CFfmpegDec::Decoder(FILE *_in, int /*OutputFd*/, State* state,
// skip frame // skip frame
packet.size = 0; packet.size = 0;
avcodec_flush_buffers(c); avcodec_flush_buffers(c);
avcodec_close(c);
avcodec_open2(c, codec, NULL);
continue; continue;
} }
if (got_frame) { if (got_frame) {