git.videolan.org
/
ffmpeg.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(from parent 1:
305b030
)
lavc/mss1: fix mem leak in case of init failure
author
Lukasz Marek
<lukasz.m.luki2@gmail.com>
Sat, 22 Nov 2014 21:56:51 +0000
(22:56 +0100)
committer
Lukasz Marek
<lukasz.m.luki2@gmail.com>
Sun, 23 Nov 2014 19:52:38 +0000
(20:52 +0100)
Signed-off-by: Lukasz Marek <lukasz.m.luki2@gmail.com>
libavcodec/mss1.c
patch
|
blob
|
history
diff --git
a/libavcodec/mss1.c
b/libavcodec/mss1.c
index
6bb524b
..
2eb67df
100644
(file)
--- a/
libavcodec/mss1.c
+++ b/
libavcodec/mss1.c
@@
-197,6
+197,8
@@
static av_cold int mss1_decode_init(AVCodecContext *avctx)
return AVERROR(ENOMEM);
ret = ff_mss12_decode_init(&c->ctx, 0, &c->sc, NULL);
+ if (ret < 0)
+ av_frame_free(&c->pic);
avctx->pix_fmt = AV_PIX_FMT_PAL8;