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:
dd195c2
)
svq1enc: check ff_get_buffer return value
author
Vittorio Giovara
<vittorio.giovara@gmail.com>
Wed, 12 Nov 2014 10:13:07 +0000
(11:13 +0100)
committer
Luca Barbato
<lu_zero@gentoo.org>
Mon, 12 Jan 2015 23:16:41 +0000
(
00:16
+0100)
CC: libav-stable@libav.org
Bug-Id: CID 747723
(cherry picked from commit
59846452af762f6af5ced4399e8dcd709ca50fcd
)
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
libavcodec/svq1enc.c
patch
|
blob
|
history
diff --git
a/libavcodec/svq1enc.c
b/libavcodec/svq1enc.c
index
361c465
..
d70bba3
100644
(file)
--- a/
libavcodec/svq1enc.c
+++ b/
libavcodec/svq1enc.c
@@
-580,8
+580,12
@@
static int svq1_encode_frame(AVCodecContext *avctx, AVPacket *pkt,
}
if (!s->current_picture->data[0]) {
- ff_get_buffer(avctx, s->current_picture, 0);
- ff_get_buffer(avctx, s->last_picture, 0);
+ ret = ff_get_buffer(avctx, s->current_picture, 0);
+ if (ret < 0)
+ return ret;
+ ret = ff_get_buffer(avctx, s->last_picture, 0);
+ if (ret < 0)
+ return ret;
s->scratchbuf = av_malloc(s->current_picture->linesize[0] * 16 * 2);
}