Furi: cleanup crash use (#3175)

* Furi: optional message in furi_crash and furi_halt
* Consistent furi_crash use
* UnitTests: crash instead of assert
* furi: check: fixed macro for default arg
* unit_tests: fixed crashes everywhere
* lib: infrared: fixed PVS warnings
* furi: eliminated __FURI_ASSERT_MESSAGE_FLAG
* Furi: update check.h docs
* Furi: add check.h usage note
* Docs: grammar

---------

Co-authored-by: hedger <hedger@nanode.su>
This commit is contained in:
あく
2023-10-31 14:40:32 +04:00
committed by GitHub
co-authored by hedger
parent c8180747db
commit 9af81ce8d0
37 changed files with 159 additions and 107 deletions
@@ -68,7 +68,7 @@ bool desktop_settings_scene_pin_auth_on_event(void* context, SceneManagerEvent e
} else if(state == SCENE_STATE_PIN_AUTH_DISABLE) {
scene_manager_next_scene(app->scene_manager, DesktopSettingsAppScenePinDisable);
} else {
furi_assert(0);
furi_crash();
}
consumed = true;
break;
@@ -39,7 +39,7 @@ void desktop_settings_scene_pin_error_on_enter(void* context) {
} else if(state == SCENE_STATE_PIN_ERROR_WRONG) {
desktop_view_pin_input_set_label_primary(app->pin_input_view, 35, 8, "Wrong PIN!");
} else {
furi_assert(0);
furi_crash();
}
desktop_view_pin_input_set_label_secondary(app->pin_input_view, 0, 8, NULL);
desktop_view_pin_input_set_label_button(app->pin_input_view, "Retry");
@@ -32,7 +32,7 @@ bool desktop_settings_scene_pin_setup_howto_on_event(void* context, SceneManager
consumed = true;
break;
default:
furi_crash(NULL);
furi_crash();
}
}
return consumed;
@@ -52,7 +52,7 @@ bool desktop_settings_scene_pin_setup_howto2_on_event(void* context, SceneManage
break;
}
default:
furi_crash(NULL);
furi_crash();
}
}
return consumed;