mtd/nvs: Fix the issue of compilation failure using the tasking compiler

the tasking compiler reports the error: expression must be constant
in line 510

Signed-off-by: zhaoxingyu1 <zhaoxingyu1@xiaomi.com>
This commit is contained in:
zhaoxingyu1
2025-03-05 13:37:46 +08:00
committed by Xiang Xiao
parent 01a70e9daf
commit 4b7b56a096
+1 -1
View File
@@ -507,7 +507,7 @@ static int nvs_flash_direct_cmp(FAR struct nvs_fs *fs, uint32_t addr1,
uint32_t addr2, size_t len)
{
uint8_t buf1[nvs_buffer_size(fs)];
uint8_t buf2[sizeof(buf1)];
uint8_t buf2[nvs_buffer_size(fs)];
size_t bytes_to_cmp;
int rc;