git.videolan.org
/
ffmpeg.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
(from parent 1:
43633c5
)
Merge commit 'c5560e72d0bb69f8a1ac9536570398f84388f396'
author
Michael Niedermayer
<michaelni@gmx.at>
Wed, 17 Sep 2014 18:38:56 +0000
(20:38 +0200)
committer
Michael Niedermayer
<michaelni@gmx.at>
Wed, 17 Sep 2014 18:42:26 +0000
(20:42 +0200)
* commit '
c5560e72d0bb69f8a1ac9536570398f84388f396
':
apetag: Fix APE tag size check
Merged-by: Michael Niedermayer <michaelni@gmx.at>
libavformat/apetag.c
patch
|
blob
|
history
diff --git
a/libavformat/apetag.c
b/libavformat/apetag.c
index
7d2f0b3
..
c8d1bdc
100644
(file)
--- a/
libavformat/apetag.c
+++ b/
libavformat/apetag.c
@@
-55,8
+55,10
@@
static int ape_tag_read_field(AVFormatContext *s)
av_log(s, AV_LOG_WARNING, "Invalid APE tag key '%s'.\n", key);
return -1;
}
- if (size >= UINT_MAX)
- return -1;
+ if (size > INT32_MAX - FF_INPUT_BUFFER_PADDING_SIZE) {
+ av_log(s, AV_LOG_ERROR, "APE tag size too large.\n");
+ return AVERROR_INVALIDDATA;
+ }
if (flags & APE_TAG_FLAG_IS_BINARY) {
uint8_t filename[1024];
enum AVCodecID id;