[kvdb] Fix get_next_kv_addr bug. #45

This commit is contained in:
armink 2021-01-23 16:05:49 +08:00
parent 9487749965
commit 119a08516c
1 changed files with 1 additions and 1 deletions

View File

@ -292,7 +292,7 @@ static uint32_t get_next_kv_addr(fdb_kvdb_t db, kv_sec_info_t sector, fdb_kv_t p
addr = pre_kv->addr.start + FDB_WG_ALIGN(1);
}
/* check and find next KV address */
addr = find_next_kv_addr(db, addr + SECTOR_HDR_DATA_SIZE, sector->addr + db_sec_size(db));
addr = find_next_kv_addr(db, addr, sector->addr + db_sec_size(db));
if (addr > sector->addr + db_sec_size(db) || pre_kv->len == 0) {
//TODO 扇区连续模式