From cf0970157dd7be238a8e7cc4917b22b3834ebd56 Mon Sep 17 00:00:00 2001 From: John Koleszar Date: Wed, 23 May 2012 12:03:39 -0700 Subject: [PATCH] Fix memory leak in vpx_codec_enc_config_set() Resolution changes in calls to vpx_codec_enc_config_set() would cause a memory leak due to failing to release the lookahead and alt ref buffers. Change-Id: I48392ea25e71fe2760d60cfde3fb3874598cc85f --- vp8/encoder/onyx_if.c | 1 + 1 file changed, 1 insertion(+) diff --git a/vp8/encoder/onyx_if.c b/vp8/encoder/onyx_if.c index cee62fa50..b7699aeb7 100644 --- a/vp8/encoder/onyx_if.c +++ b/vp8/encoder/onyx_if.c @@ -1655,6 +1655,7 @@ void vp8_change_config(VP8_COMP *cpi, VP8_CONFIG *oxcf) cm->yv12_fb[cm->lst_fb_idx].y_height || cm->yv12_fb[cm->lst_fb_idx].y_width == 0) { + dealloc_raw_frame_buffers(cpi); alloc_raw_frame_buffers(cpi); vp8_alloc_compressor_data(cpi); } -- 2.50.1