fix(snapshot) fix memory leak (#2970)

Signed-off-by: wangxuedong <wangxuedong@xiaomi.com>
Co-authored-by: Themba Dube <embeddedthemba@gmail.com>
This commit is contained in:
xaowang96
2022-01-06 21:56:53 +08:00
committed by GitHub
parent e7ac0e4198
commit ddae70f741
2 changed files with 38 additions and 0 deletions

View File

@@ -142,6 +142,7 @@ lv_res_t lv_snapshot_take_to_buf(lv_obj_t * obj, lv_img_cf_t cf, lv_img_dsc_t *
_lv_refr_set_disp_refreshing(refr_ori);
obj_disp->driver->draw_ctx_deinit(fake_disp.driver, draw_ctx);
lv_mem_free(draw_ctx);
dsc->data = buf;
dsc->header.w = w;