[FFmpeg-cvslog] r20744 - trunk/libavformat/utils.c
daniel
subversion
Sun Dec 6 01:03:53 CET 2009
Author: daniel
Date: Sun Dec 6 01:03:53 2009
New Revision: 20744
Log:
Calls to url_fseek should have their return value checked in
av_seek_frame_binary, just as they do in av_seek_frame_generic.
Otherwise, function may return success even though url_fseek reported
failure.
Patch by Sean Soria, first.last at gmail
Modified:
trunk/libavformat/utils.c
Modified: trunk/libavformat/utils.c
==============================================================================
--- trunk/libavformat/utils.c Sat Dec 5 18:53:11 2009 (r20743)
+++ trunk/libavformat/utils.c Sun Dec 6 01:03:53 2009 (r20744)
@@ -1311,6 +1311,7 @@ int av_seek_frame_binary(AVFormatContext
int64_t av_uninit(pos_min), av_uninit(pos_max), pos, pos_limit;
int64_t ts_min, ts_max, ts;
int index;
+ int64_t ret;
AVStream *st;
if (stream_index < 0)
@@ -1363,7 +1364,8 @@ int av_seek_frame_binary(AVFormatContext
return -1;
/* do the seek */
- url_fseek(s->pb, pos, SEEK_SET);
+ if ((ret = url_fseek(s->pb, pos, SEEK_SET)) < 0)
+ return ret;
av_update_cur_dts(s, st, ts);
More information about the ffmpeg-cvslog
mailing list