X-Git-Url: https://git.gag.com/?p=fw%2Faltos;a=blobdiff_plain;f=src%2Fstm32l0%2Fao_flash_stm32l0.c;fp=src%2Fstm32l0%2Fao_flash_stm32l0.c;h=521c5c0cfbb95d56317440c6c7be6bb55a0c5cde;hp=ba3274422ef969797bb50b0e28e7eb3b6868fa15;hb=2d4484e1577edc66c52bcb260329387f93123a6d;hpb=5b3a457f232e39977a437fc52256fc15c612b377 diff --git a/src/stm32l0/ao_flash_stm32l0.c b/src/stm32l0/ao_flash_stm32l0.c index ba327442..521c5c0c 100644 --- a/src/stm32l0/ao_flash_stm32l0.c +++ b/src/stm32l0/ao_flash_stm32l0.c @@ -186,7 +186,7 @@ ao_storage_device_write(ao_pos_t pos, void *buf, uint16_t len) flash_write_select(this_pos); /* Update write buffer with new contents */ - int this_word = 4 - (pos & 3); + uint16_t this_word = 4 - (pos & 3); if (this_word > len) this_word = len; memcpy(&write_buf.u8[pos & 3], b8, this_word);