# HG changeset patch # User michael # Date 1106361045 0 # Node ID 6a5ba24b2c6b773d7d5423bc565e10c65d951953 # Parent c129846f7f02863ef003938b2ee96e266f468584 fixing demuxing for short files where the framerate detection failed diff -r c129846f7f02 -r 6a5ba24b2c6b utils.c --- a/utils.c Sat Jan 22 01:48:11 2005 +0000 +++ b/utils.c Sat Jan 22 02:30:45 2005 +0000 @@ -1783,6 +1783,11 @@ if (ret < 0) { /* EOF or error */ ret = -1; /* we could not have all the codec parameters before EOF */ + for(i=0;inb_streams;i++) { + st = ic->streams[i]; + if (!has_codec_parameters(&st->codec)) + break; + } if ((ic->ctx_flags & AVFMTCTX_NOHEADER) && i == ic->nb_streams) ret = 0;