NFS: nfs_find_open_context() may only select open files

[ Upstream commit e97bc66377 ]

If a file has already been closed, then it should not be selected to
support further I/O.

Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
[Trond: Fix an invalid pointer deref reported by Colin Ian King]
Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
Trond Myklebust 2021-05-11 23:41:10 -04:00 • committed by Greg Kroah-Hartman
commit 89786fbc4d
2 changed files with 5 additions and 0 deletions