Commit 404e998e authored by Yaowu Xu's avatar Yaowu Xu Committed by Code Review

Merge "mem leak fix for cpi->tplist"

parents d419b93e d3dfcde0
......@@ -262,7 +262,8 @@ static void setup_features(VP8_COMP *cpi)
void vp8_dealloc_compressor_data(VP8_COMP *cpi)
{
vpx_free(cpi->tplist);
if(cpi->tplist!=0)
vpx_free(cpi->tplist);
cpi->tplist = NULL;
// Delete last frame MV storage buffers
......@@ -1406,6 +1407,9 @@ void vp8_alloc_compressor_data(VP8_COMP *cpi)
cpi->mt_sync_range = 16;
#endif
if(cpi->tplist);
vpx_free(cpi->tplist);
CHECK_MEM_ERROR(cpi->tplist, vpx_malloc(sizeof(TOKENLIST) * cpi->common.mb_rows));
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment