mirror of
https://github.com/nxp-imx/linux-imx.git
synced 2025-07-19 07:39:54 +02:00
nfsd: fix refcount leak when file is unhashed after being found
If we wait_for_construction and find that the file is no longer hashed,
and we're going to retry the open, the old nfsd_file reference is
currently leaked. Put the reference before retrying.
Fixes: c6593366c0
("nfsd: don't kill nfsd_files because of lease break error")
Signed-off-by: Jeff Layton <jlayton@kernel.org>
Tested-by: Youzhong Yang <youzhong@gmail.com>
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
This commit is contained in:
parent
81a95c2b1d
commit
8a79261763
|
@ -1051,6 +1051,7 @@ wait_for_construction:
|
|||
status = nfserr_jukebox;
|
||||
goto construction_err;
|
||||
}
|
||||
nfsd_file_put(nf);
|
||||
open_retry = false;
|
||||
fh_put(fhp);
|
||||
goto retry;
|
||||
|
|
Loading…
Reference in New Issue
Block a user