projects
/
platform
/
upstream
/
libav.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
273aab9
)
Check for invalid packet size in the smacker demuxer.
author
Laurent Aimar
<fenrir@videolan.org>
Mon, 12 Sep 2011 18:50:13 +0000
(20:50 +0200)
committer
Martin Storsjö
<martin@martin.st>
Mon, 12 Sep 2011 20:43:52 +0000
(23:43 +0300)
Signed-off-by: Martin Storsjö <martin@martin.st>
libavformat/smacker.c
patch
|
blob
|
history
diff --git
a/libavformat/smacker.c
b/libavformat/smacker.c
index
2749466
..
cff1af6
100644
(file)
--- a/
libavformat/smacker.c
+++ b/
libavformat/smacker.c
@@
-304,6
+304,8
@@
static int smacker_read_packet(AVFormatContext *s, AVPacket *pkt)
}
flags >>= 1;
}
+ if (frame_size < 0)
+ return AVERROR_INVALIDDATA;
if (av_new_packet(pkt, frame_size + 768))
return AVERROR(ENOMEM);
if(smk->frm_size[smk->cur_frame] & 1)