Commit 3148a03f authored by bcoudurier's avatar bcoudurier

fetch flv duration from file if it is set to 0 in metadata

git-svn-id: file:///var/local/repositories/ffmpeg/trunk@21329 9553f0bf-9b14-0410-a0b8-cfaf0461ba5b
parent 6cb2817b
...@@ -362,7 +362,7 @@ static int flv_read_packet(AVFormatContext *s, AVPacket *pkt) ...@@ -362,7 +362,7 @@ static int flv_read_packet(AVFormatContext *s, AVPacket *pkt)
} }
// if not streamed and no duration from metadata then seek to end to find the duration from the timestamps // if not streamed and no duration from metadata then seek to end to find the duration from the timestamps
if(!url_is_streamed(s->pb) && s->duration==AV_NOPTS_VALUE){ if(!url_is_streamed(s->pb) && (!s->duration || s->duration==AV_NOPTS_VALUE)){
int size; int size;
const int64_t pos= url_ftell(s->pb); const int64_t pos= url_ftell(s->pb);
const int64_t fsize= url_fsize(s->pb); const int64_t fsize= url_fsize(s->pb);
......
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