| commit | 02de03bfc59474eddfa3d60a515367bcaa34c58d | [log] [tgz] |
|---|---|---|
| author | Gao Xiang <hsiangkao@linux.alibaba.com> | Thu Jun 26 08:32:19 2025 +0800 |
| committer | Gao Xiang <xiang@kernel.org> | Thu Jun 26 08:35:37 2025 +0800 |
| tree | eeb170530af0fb52bfdb15d876019e7c497dbced | |
| parent | 61ed98bf4b9b560945d7b1f4a47fff03ffa0dcd1 [diff] |
erofs-utils: lib: fix small fragments again `inode->fragment = NULL;` overrides `inode->fragmentoff`, which is unintended. In fact, the latest stress test [1] had already failed, but I didn't notice it. Fedora openQA tests [2] also reported the issue. [1] https://github.com/erofs/erofsstress/actions/runs/15881657361 [2] https://bodhi.fedoraproject.org/updates/FEDORA-2025-e6256ddcc4 Fixes: 9fa1a5838a2a ("erofs-utils: mkfs: fix memory leak from small fragments") Signed-off-by: Gao Xiang <hsiangkao@linux.alibaba.com> Link: https://lore.kernel.org/r/20250626003219.3866538-1-hsiangkao@linux.alibaba.com
diff --git a/lib/fragments.c b/lib/fragments.c index 6111631..3278f47 100644 --- a/lib/fragments.c +++ b/lib/fragments.c
@@ -365,7 +365,6 @@ return 0; } inode->fragmentoff = (erofs_off_t)offset - len; - inode->fragment = NULL; free(fi->data); free(fi); return 0;