Skip to content

Commit

Permalink
Merge pull request ARMmbed#103 from juhoeskeli/IOTUC-333
Browse files Browse the repository at this point in the history
Fix for erase size calculation when header is contiguous with app.
  • Loading branch information
LiyouZhou authored May 8, 2018
2 parents ddf74c6 + 98f9d57 commit e31ea41
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion source/active_application.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -257,7 +257,7 @@ bool eraseActiveFirmware(uint32_t firmwareSize)
else /* header contiguous with app */
{
/* setup erase of the header + application region */
size_needed = fw_metadata_hdr_size + firmwareSize;
size_needed = (MBED_CONF_APP_APPLICATION_START_ADDRESS - FIRMWARE_METADATA_HEADER_ADDRESS) + firmwareSize;
erase_start_addr = FIRMWARE_METADATA_HEADER_ADDRESS;
}

Expand Down

0 comments on commit e31ea41

Please sign in to comment.