summaryrefslogtreecommitdiff
path: root/libavformat/matroskadec.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2013-03-19 14:07:39 +0100
committerMichael Niedermayer <michaelni@gmx.at>2013-03-19 14:33:47 +0100
commitfdda9b440c0a0b1a8e2b08ddf1c37e98c26e6296 (patch)
tree03973258f4a3f9292b1770656df2256c7aa919f3 /libavformat/matroskadec.c
parentdec9800c9dc9f8effe758c18fc914b0c31c1e38e (diff)
matroska_parse_frame: fix memleak
Fixes CID991856 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavformat/matroskadec.c')
-rw-r--r--libavformat/matroskadec.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/libavformat/matroskadec.c b/libavformat/matroskadec.c
index 26b218663b..115c9265eb 100644
--- a/libavformat/matroskadec.c
+++ b/libavformat/matroskadec.c
@@ -2140,6 +2140,8 @@ static int matroska_parse_frame(MatroskaDemuxContext *matroska,
AV_PKT_DATA_MATROSKA_BLOCKADDITIONAL,
additional_size + 8);
if(side_data == NULL) {
+ av_free_packet(pkt);
+ av_free(pkt);
return AVERROR(ENOMEM);
}
AV_WB64(side_data, additional_id);