mirror of
https://github.com/DarkFlippers/unleashed-firmware
synced 2024-11-15 01:07:22 +00:00
Gui, module menu: fix memleak
This commit is contained in:
parent
dd1a92803e
commit
8cfb37c12f
1 changed files with 2 additions and 0 deletions
|
@ -154,6 +154,8 @@ Menu* menu_alloc() {
|
||||||
void menu_free(Menu* menu) {
|
void menu_free(Menu* menu) {
|
||||||
furi_assert(menu);
|
furi_assert(menu);
|
||||||
menu_reset(menu);
|
menu_reset(menu);
|
||||||
|
with_view_model(
|
||||||
|
menu->view, MenuModel * model, { MenuItemArray_clear(model->items); }, false);
|
||||||
view_free(menu->view);
|
view_free(menu->view);
|
||||||
free(menu);
|
free(menu);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue