mirror of
https://github.com/CTCaer/hekate.git
synced 2025-10-05 23:52:39 +02:00
nyx: clear B button context on option actions
Fixes an issue that was causing an NULL pointer dereference when a certain access path was followed
This commit is contained in:
@@ -122,7 +122,6 @@ lv_obj_t *create_window_autoboot(const char *win_title)
|
||||
return win;
|
||||
}
|
||||
|
||||
// TODO: instant update of button for these.
|
||||
static lv_res_t _autoboot_disable_action(lv_obj_t *btn)
|
||||
{
|
||||
h_cfg.autoboot = 0;
|
||||
@@ -136,6 +135,8 @@ static lv_res_t _autoboot_disable_action(lv_obj_t *btn)
|
||||
|
||||
lv_obj_del(win);
|
||||
|
||||
close_btn = NULL;
|
||||
|
||||
return LV_RES_OK;
|
||||
}
|
||||
|
||||
@@ -155,6 +156,8 @@ static lv_res_t _autoboot_enable_main_action(lv_obj_t *btn)
|
||||
obj = lv_obj_get_parent(obj);
|
||||
lv_obj_del(obj);
|
||||
|
||||
close_btn = NULL;
|
||||
|
||||
return LV_RES_INV;
|
||||
}
|
||||
|
||||
@@ -172,6 +175,8 @@ static lv_res_t _autoboot_enable_more_action(lv_obj_t *btn)
|
||||
obj = lv_obj_get_parent(obj);
|
||||
lv_obj_del(obj);
|
||||
|
||||
close_btn = NULL;
|
||||
|
||||
return LV_RES_INV;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user