[FFmpeg-cvslog] avformat/rmdec: Don't rely on unspecified order of evaluation

Andreas Rheinhardt git at videolan.org
Thu Apr 8 13:53:46 EEST 2021


ffmpeg | branch: release/4.4 | Andreas Rheinhardt <andreas.rheinhardt at outlook.com> | Wed Apr  7 13:37:09 2021 +0200| [44d218e99aba4cbcbbed06bc5065380636623a36] | committer: Andreas Rheinhardt

avformat/rmdec: Don't rely on unspecified order of evaluation

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt at outlook.com>
(cherry picked from commit 4666ce0aef395fc7dfa2a718e8d238e58e635d2a)

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=44d218e99aba4cbcbbed06bc5065380636623a36
---

 libavformat/rmdec.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavformat/rmdec.c b/libavformat/rmdec.c
index 1dec70e95b..fc3bff4859 100644
--- a/libavformat/rmdec.c
+++ b/libavformat/rmdec.c
@@ -1312,7 +1312,7 @@ static int ivr_read_header(AVFormatContext *s)
     if (avio_r8(pb) != 6)
         goto invalid_data;
     avio_skip(pb, 12);
-    avio_skip(pb, avio_rb64(pb) + pos - avio_tell(s->pb));
+    avio_seek(pb, avio_rb64(pb) + pos, SEEK_SET);
     if (avio_r8(pb) != 8)
         goto invalid_data;
     avio_skip(pb, 8);



More information about the ffmpeg-cvslog mailing list