mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Qianqiang Liu <qianqiang.liu@163.com>
To: almaz.alexandrovich@paragon-software.com
Cc: ntfs3@lists.linux.dev, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] fs/ntfs3: Remove the unnecessary 'if' statement
Date: Fri, 13 Sep 2024 10:33:27 +0800	[thread overview]
Message-ID: <ZuOkd8dMur08t0zo@iZbp1asjb3cy8ks0srf007Z> (raw)
In-Reply-To: <20240911015753.49513-1-qianqiang.liu@163.com>

Hi almaz,

On Wed, Sep 11, 2024 at 09:57:54AM +0800, Qianqiang Liu wrote:
> The 'asize' was already checked to be less than SIZEOF_RESIDENT.
> 
> Signed-off-by: Qianqiang Liu <qianqiang.liu@163.com>
> ---
>  fs/ntfs3/record.c | 4 ----
>  1 file changed, 4 deletions(-)
> 
> diff --git a/fs/ntfs3/record.c b/fs/ntfs3/record.c
> index 427c71be0f08..0f400366231d 100644
> --- a/fs/ntfs3/record.c
> +++ b/fs/ntfs3/record.c
> @@ -268,10 +268,6 @@ struct ATTRIB *mi_enum_attr(struct mft_inode *mi, struct ATTRIB *attr)
>  
>  	/* Check size of attribute. */
>  	if (!attr->non_res) {
> -		/* Check resident fields. */
> -		if (asize < SIZEOF_RESIDENT)
> -			return NULL;
> -
>  		t16 = le16_to_cpu(attr->res.data_off);
>  		if (t16 > asize)
>  			return NULL;
> -- 
> 2.39.2

Could you please review this patch?

-- 
Best,
Qianqiang Liu


      reply	other threads:[~2024-09-13  2:33 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-09-11  1:57 Qianqiang Liu
2024-09-13  2:33 ` Qianqiang Liu [this message]

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=ZuOkd8dMur08t0zo@iZbp1asjb3cy8ks0srf007Z \
    --to=qianqiang.liu@163.com \
    --cc=almaz.alexandrovich@paragon-software.com \
    --cc=linux-kernel@vger.kernel.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®