Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions core/recovery.c
Original file line number Diff line number Diff line change
Expand Up @@ -284,7 +284,6 @@ static int recovery_handle_write(eos_slot_t slot, uint32_t offset, uint16_t len)
/* offset/len come straight from the wire; without this check a
* recovery client can write past the slot boundary into the other
* slot, boot-control blocks, or the boot log. */
uint32_t slot_size = eos_hal_slot_size(slot);
if (slot_size == 0 || (uint64_t)offset + len > (uint64_t)slot_size)
return recovery_send_nack();

Expand Down Expand Up @@ -514,4 +513,4 @@ int eos_recovery_enter(eos_bootctl_t *bctl)
}

return EOS_OK;
}
}
2 changes: 1 addition & 1 deletion include/eos_image.h
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ int eos_crc32_checked(uint32_t addr, size_t len, uint32_t *out_crc);
* @param len Length in bytes.
* @return CRC32 value, or 0 if the region could not be read.
*/
int eos_crc32(uint32_t addr, size_t len, uint32_t *out);
uint32_t eos_crc32(uint32_t addr, size_t len);

#ifdef __cplusplus
}
Expand Down