Commit a58873b1 authored by Peter Große's avatar Peter Große Committed by Anton Khirnov

avconv: when using -loop option bail out if seek to start fails

Fixes an infinite loop when a demuxer fails to seek to the start of the input.
Signed-off-by: 's avatarPeter Große <pegro@friiks.de>
Signed-off-by: 's avatarAnton Khirnov <anton@khirnov.net>
parent 004ea637
......@@ -2615,8 +2615,10 @@ static int process_input(void)
return ret;
}
if (ret < 0 && ifile->loop) {
if ((ret = seek_to_start(ifile, is)) < 0)
return ret;
ret = seek_to_start(ifile, is);
if(ret < 0)
av_log(NULL, AV_LOG_WARNING, "Seek to start failed.\n");
else
ret = get_input_packet(ifile, &pkt);
}
if (ret < 0) {
......
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