NFS: Fix use after free in write error path
Signed-off-by: Fred Isaman <fred.isaman@gmail.com>
Fixes: 0bcbf039f6
("nfs: handle request add failure properly")
Cc: stable@vger.kernel.org # v4.5+
Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com>
This commit is contained in:
parent
43b7d964ed
commit
1f84ccdf37
|
@ -561,9 +561,9 @@ static void nfs_write_error_remove_page(struct nfs_page *req)
|
|||
{
|
||||
nfs_unlock_request(req);
|
||||
nfs_end_page_writeback(req);
|
||||
nfs_release_request(req);
|
||||
generic_error_remove_page(page_file_mapping(req->wb_page),
|
||||
req->wb_page);
|
||||
nfs_release_request(req);
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
Loading…
Reference in New Issue