From: Daeho Jeong <[email protected]>
We might allocate more node blocks than total_valid_node_count, when we
recreate quota files.
Signed-off-by: Daeho Jeong <[email protected]>
---
fsck/segment.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/fsck/segment.c b/fsck/segment.c
index 4b05fd4..4ea0a6f 100644
--- a/fsck/segment.c
+++ b/fsck/segment.c
@@ -36,8 +36,8 @@ int reserve_new_block(struct f2fs_sb_info *sbi, block_t *to,
ERR_MSG("Not enough space\n");
return -ENOSPC;
}
- if (is_node && fsck->chk.valid_node_cnt >
- sbi->total_valid_node_count) {
+ if (is_node && fsck->chk.valid_node_cnt >=
+ sbi->total_node_count) {
ERR_MSG("Not enough space for node block\n");
return -ENOSPC;
}
--
2.42.0.820.g83a721a137-goog
On 2023/10/27 23:30, Daeho Jeong wrote:
> From: Daeho Jeong <[email protected]>
>
> We might allocate more node blocks than total_valid_node_count, when we
> recreate quota files.
>
> Signed-off-by: Daeho Jeong <[email protected]>
Reviewed-by: Chao Yu <[email protected]>
Thanks,