1
0
mirror of https://github.com/lvgl/lvgl.git synced 2025-01-14 06:42:58 +08:00

fix: add assert in lv_obj_get_style_prop (#4405)

Co-authored-by: Igor Parfenov <i.parfenov@omp.ru>
This commit is contained in:
Igor Parfenov 2023-07-25 21:42:57 +03:00 committed by GitHub
parent dbde799ada
commit 469b66edc8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -288,6 +288,8 @@ void lv_obj_enable_style_refresh(bool en)
lv_style_value_t lv_obj_get_style_prop(const lv_obj_t * obj, lv_part_t part, lv_style_prop_t prop) lv_style_value_t lv_obj_get_style_prop(const lv_obj_t * obj, lv_part_t part, lv_style_prop_t prop)
{ {
LV_ASSERT_NULL(obj)
lv_style_value_t value_act = { .ptr = NULL }; lv_style_value_t value_act = { .ptr = NULL };
bool inheritable = lv_style_prop_has_flag(prop, LV_STYLE_PROP_FLAG_INHERITABLE); bool inheritable = lv_style_prop_has_flag(prop, LV_STYLE_PROP_FLAG_INHERITABLE);
lv_style_res_t found = LV_STYLE_RES_NOT_FOUND; lv_style_res_t found = LV_STYLE_RES_NOT_FOUND;