OSDN Git Service
(root)
/
android-x86
/
external-ffmpeg.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5bcd3ae
)
4xm: Check that the read track value is non-negative
author
Martin Storsjö
<martin@martin.st>
Tue, 3 Sep 2013 10:53:23 +0000
(13:53 +0300)
committer
Martin Storsjö
<martin@martin.st>
Tue, 3 Sep 2013 19:57:36 +0000
(22:57 +0300)
Reported-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
CC: libav-stable@libav.org
Signed-off-by: Martin Storsjö <martin@martin.st>
libavformat/4xm.c
patch
|
blob
|
history
diff --git
a/libavformat/4xm.c
b/libavformat/4xm.c
index
f003c9c
..
7a87c36
100644
(file)
--- a/
libavformat/4xm.c
+++ b/
libavformat/4xm.c
@@
-131,6
+131,8
@@
static int parse_strk(AVFormatContext *s,
return AVERROR_INVALIDDATA;
track = AV_RL32(buf + 8);
+ if (track < 0)
+ return AVERROR_INVALIDDATA;
if (track + 1 > fourxm->track_count) {
if (av_reallocp_array(&fourxm->tracks, track + 1, sizeof(AudioTrack)))
return AVERROR(ENOMEM);