[lvc-project] [PATCH] fs/ntfs3: remove redundant if-block in check_attr()
Matvey Kovalev
matvey.kovalev at ispras.ru
Sun Jul 19 23:25:16 MSK 2026
Condition of this if-block repeats another one from if-block above. So,
condition is always false.
Found by Linux Verification Center (linuxtesting.org) with SVACE.
Signed-off-by: Matvey Kovalev <matvey.kovalev at ispras.ru>
---
fs/ntfs3/fslog.c | 3 ---
1 file changed, 3 deletions(-)
diff --git a/fs/ntfs3/fslog.c b/fs/ntfs3/fslog.c
index f038c799e7ac..7c40eff69959 100644
--- a/fs/ntfs3/fslog.c
+++ b/fs/ntfs3/fslog.c
@@ -2753,9 +2753,6 @@ static inline bool check_attr(const struct MFT_REC *rec,
return false;
}
- if (run_off > asize)
- return false;
-
if (run_unpack(NULL, sbi, 0, svcn, evcn, svcn,
Add2Ptr(attr, run_off), asize - run_off) < 0) {
return false;
--
2.54.0
More information about the lvc-project
mailing list