We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b01b1e0 commit 4d9ed52Copy full SHA for 4d9ed52
boot/bootutil/src/bootutil_misc.c
@@ -643,15 +643,9 @@ const struct image_max_size *boot_get_max_app_size(void)
643
* Clears the boot state, so that previous operations have no effect on new
644
* ones.
645
*
646
- * @param state The state that should be cleared. If the value
647
- * is NULL, the default bootloader state will be
648
- * cleared.
+ * @param state The state that should be cleared.
649
*/
650
void boot_state_clear(struct boot_loader_state *state)
651
{
652
- if (state != NULL) {
653
- memset(state, 0, sizeof(struct boot_loader_state));
654
- } else {
655
- memset(boot_get_loader_state(), 0, sizeof(struct boot_loader_state));
656
- }
+ memset(state, 0, sizeof(struct boot_loader_state));
657
}
0 commit comments