Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Michael Niedermayer authored on 2015/11/13 21:32:13... | ... |
@@ -296,13 +296,14 @@ static int film_read_seek(AVFormatContext *s, int stream_index, int64_t timestam |
296 | 296 |
{ |
297 | 297 |
FilmDemuxContext *film = s->priv_data; |
298 | 298 |
AVStream *st = s->streams[stream_index]; |
299 |
+ int64_t pos; |
|
299 | 300 |
int ret = av_index_search_timestamp(st, timestamp, flags); |
300 | 301 |
if (ret < 0) |
301 | 302 |
return ret; |
302 | 303 |
|
303 |
- ret = avio_seek(s->pb, st->index_entries[ret].pos, SEEK_SET); |
|
304 |
- if (ret < 0) |
|
305 |
- return ret; |
|
304 |
+ pos = avio_seek(s->pb, st->index_entries[ret].pos, SEEK_SET); |
|
305 |
+ if (pos < 0) |
|
306 |
+ return pos; |
|
306 | 307 |
|
307 | 308 |
film->current_sample = ret; |
308 | 309 |
|