From: Matvey Kovalev <matvey.kovalev@ispras.ru>
To: matvey.kovalev@ispras.ru,
Konstantin Komarov <almaz.alexandrovich@paragon-software.com>
Cc: ntfs3@lists.linux.dev, linux-kernel@vger.kernel.org,
lvc-project@linuxtesting.org
Subject: [PATCH] fs/ntfs3: remove redundant if-block in check_attr()
Date: Sun, 19 Jul 2026 23:25:16 +0300 [thread overview]
Message-ID: <20260719202534.2942-1-matvey.kovalev@ispras.ru> (raw)
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@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
next reply other threads:[~2026-07-19 20:26 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-07-19 20:25 Matvey Kovalev [this message]
2026-10-07 21:32 ` Konstantin Komarov
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260719202534.2942-1-matvey.kovalev@ispras.ru \
--to=matvey.kovalev@ispras.ru \
--cc=almaz.alexandrovich@paragon-software.com \
--cc=linux-kernel@vger.kernel.org \
--cc=lvc-project@linuxtesting.org \
--cc=ntfs3@lists.linux.dev \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®