Skip to content

Commit de06a61

Browse files
committed
QSPIFlashBlockDevice: fix pointer aritmetic
1 parent a8d4998 commit de06a61

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

libraries/BlockDevices/QSPIFlashBlockDevice.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -287,7 +287,7 @@ int QSPIFlashBlockDevice::write(const void *buffer, bd_addr_t add, bd_size_t _si
287287
R_QSPI_BankSet(&ctrl, bank);
288288
rv = R_QSPI_Write(&ctrl, (uint8_t *)(buffer), (uint8_t*)address, chunk);
289289
address += chunk;
290-
buffer += chunk;
290+
buffer = (uint8_t *)(buffer) + chunk;
291291

292292
if(rv == FSP_SUCCESS) {
293293
rv = get_flash_status();

0 commit comments

Comments
 (0)