# HG changeset patch # User reimar # Date 1368084274 0 # Node ID 749f1c5c4267bbcaaa244cfc5a2da6e9e48e793a # Parent 868f3a141dcaa5142ed9cd50cfecee059abbc128 Make parser allocation work if a codec was forced. diff -r 868f3a141dca -r 749f1c5c4267 libmpdemux/demuxer.c --- a/libmpdemux/demuxer.c Thu May 09 07:18:48 2013 +0000 +++ b/libmpdemux/demuxer.c Thu May 09 07:24:34 2013 +0000 @@ -32,6 +32,7 @@ #include "help_mp.h" #include "m_config.h" #include "mpcommon.h" +#include "codec-cfg.h" #include "libvo/fastmemcpy.h" @@ -561,6 +562,8 @@ return; allocate_parser(avctx, parser, sh->format); + if (!*parser && sh->codec) // fallback to support forcing a codec + allocate_parser(avctx, parser, sh->codec->fourcc[0]); sh->avctx = *avctx; sh->parser = *parser; }