lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAD+ocbz+DKHKGN=G8Vn0pjuAfVRX3UP85ZaeZEEwcNemS1kJ8A@mail.gmail.com>
Date:   Wed, 20 Jan 2021 09:43:16 -0800
From:   harshad shirwadkar <harshadshirwadkar@...il.com>
To:     Pan Bian <bianpan2016@....com>
Cc:     "Theodore Ts'o" <tytso@....edu>,
        Andreas Dilger <adilger.kernel@...ger.ca>,
        Ext4 Developers List <linux-ext4@...r.kernel.org>,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH] ext4: stop update inode before return

Thanks Pan for the fix. Looks good to me.

Reviewed-by: Harshad Shirwadkar <harshadshirwadkar@...il.com>

On Tue, Jan 19, 2021 at 3:04 AM Pan Bian <bianpan2016@....com> wrote:
>
> Stop inode updating before returning the error code.
>
> Fixes: aa75f4d3daae ("ext4: main fast-commit commit path")
> Signed-off-by: Pan Bian <bianpan2016@....com>
> ---
>  fs/ext4/inode.c | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
>
> diff --git a/fs/ext4/inode.c b/fs/ext4/inode.c
> index c173c8405856..64039bbb656d 100644
> --- a/fs/ext4/inode.c
> +++ b/fs/ext4/inode.c
> @@ -5389,8 +5389,10 @@ int ext4_setattr(struct dentry *dentry, struct iattr *attr)
>                         inode->i_gid = attr->ia_gid;
>                 error = ext4_mark_inode_dirty(handle, inode);
>                 ext4_journal_stop(handle);
> -               if (unlikely(error))
> +               if (unlikely(error)) {
> +                       ext4_fc_stop_update(inode);
>                         return error;
> +               }
>         }
>
>         if (attr->ia_valid & ATTR_SIZE) {
> --
> 2.17.1
>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ