aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2015-02-20 19:29:12 +0100
committerMichael Niedermayer <michaelni@gmx.at>2015-03-14 14:27:22 +0100
commita15ceebb6f2a7b6b8731793d9b8a1f565740ba50 (patch)
tree6245aa2b49ce653b27a7e64e250bc1171e8918a6
parent7a3ff7fb814bfecd4395427b52391c7ccb9561e0 (diff)
downloadffmpeg-a15ceebb6f2a7b6b8731793d9b8a1f565740ba50.tar.gz
avformat/asfdec: Use 64bit ret to avoid overflow
Signed-off-by: Michael Niedermayer <michaelni@gmx.at> (cherry picked from commit d4936d28a11fac6c9c4b4df9625185f93b086986) Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
-rw-r--r--libavformat/asfdec.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libavformat/asfdec.c b/libavformat/asfdec.c
index 9bbc70467d..51ff96b769 100644
--- a/libavformat/asfdec.c
+++ b/libavformat/asfdec.c
@@ -1472,7 +1472,7 @@ static int asf_build_simple_index(AVFormatContext *s, int stream_index)
ff_asf_guid g;
ASFContext *asf = s->priv_data;
int64_t current_pos = avio_tell(s->pb);
- int ret = 0;
+ int64_t ret;
if((ret = avio_seek(s->pb, asf->data_object_offset + asf->data_object_size, SEEK_SET)) < 0) {
return ret;
@@ -1542,7 +1542,7 @@ static int asf_read_seek(AVFormatContext *s, int stream_index,
/* Try using the protocol's read_seek if available */
if (s->pb) {
- int ret = avio_seek_time(s->pb, stream_index, pts, flags);
+ int64_t ret = avio_seek_time(s->pb, stream_index, pts, flags);
if (ret >= 0)
asf_reset_header(s);
if (ret != AVERROR(ENOSYS))