Skip to content

Commit 845f7f3

Browse files
MrSmoergatk555
authored andcommitted
Fix: avr_flash_t's tmppage was cleared to 0x00ff -> 0xffff in avr_flash_clear_temppage
avr_flash_t's tmppage is of type uint16_t* and in avr_flash_clear_temppage it is reset to 0xff, which results to a pattern of 0x00ff00ff00ff in the tmppage. This is supposed to be reset to 0xffff :)
1 parent add07c6 commit 845f7f3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

simavr/sim/avr_flash.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ avr_flash_clear_temppage(
5959
avr_flash_t *p)
6060
{
6161
for (int i = 0; i < p->spm_pagesize / 2; i++) {
62-
p->tmppage[i] = 0xff;
62+
p->tmppage[i] = 0xffff;
6363
p->tmppage_used[i] = 0;
6464
}
6565
}

0 commit comments

Comments
 (0)