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:
0872bb2
)
ape demuxer: fix segfault on memory allocation failure.
author
Laurent Aimar
<fenrir@videolan.org>
Sun, 11 Sep 2011 17:17:40 +0000
(19:17 +0200)
committer
Anton Khirnov
<anton@khirnov.net>
Mon, 12 Sep 2011 19:12:31 +0000
(21:12 +0200)
Signed-off-by: Anton Khirnov <anton@khirnov.net>
libavformat/ape.c
patch
|
blob
|
history
diff --git
a/libavformat/ape.c
b/libavformat/ape.c
index
a49da5c
..
088515c
100644
(file)
--- a/
libavformat/ape.c
+++ b/
libavformat/ape.c
@@
-273,6
+273,8
@@
static int ape_read_header(AVFormatContext * s, AVFormatParameters * ap)
if (ape->seektablelength > 0) {
ape->seektable = av_malloc(ape->seektablelength);
+ if (!ape->seektable)
+ return AVERROR(ENOMEM);
for (i = 0; i < ape->seektablelength / sizeof(uint32_t); i++)
ape->seektable[i] = avio_rl32(pb);
}