[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <1589570568.5111.46.camel@linux.ibm.com>
Date: Fri, 15 May 2020 15:22:48 -0400
From: Mimi Zohar <zohar@...ux.ibm.com>
To: Shuah Khan <skhan@...uxfoundation.org>, viro@...iv.linux.org.uk,
axboe@...nel.dk, zohar@...ux.vnet.ibm.com, mcgrof@...nel.org,
keescook@...omium.org
Cc: linux-fsdevel@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v3 2/2] fs: avoid fdput() after failed fdget() in
kernel_read_file_from_fd()
On Wed, 2020-05-13 at 17:33 -0600, Shuah Khan wrote:
> Fix kernel_read_file_from_fd() to avoid fdput() after a failed fdget().
> fdput() doesn't do fput() on this file since FDPUT_FPUT isn't set
> in fd.flags. Fix it anyway since failed fdget() doesn't require
> a fdput().
>
> This was introduced in a commit that added kernel_read_file_from_fd() as
> a wrapper for the VFS common kernel_read_file().
>
> Fixes: b844f0ecbc56 ("vfs: define kernel_copy_file_from_fd()")
> Signed-off-by: Shuah Khan <skhan@...uxfoundation.org>
Thanks, Shuah.
Reviewed-by: Mimi Zohar <zohar@...ux.ibm.com>
Powered by blists - more mailing lists