NFS: fix handling of malloc failure during nfs_flush_multi()
Cleanup of the allocated list entries should not call put_nfs_open_context() on each entry, as the context will always be NULL, causing an oops. Signed-off-by: Fred Isaman <iisaman@netapp.com> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
This commit is contained in:
committed by
Trond Myklebust
parent
c56eb8fb6d
commit
0da2a4ac33
@@ -932,7 +932,7 @@ out_bad:
|
|||||||
while (!list_empty(&list)) {
|
while (!list_empty(&list)) {
|
||||||
data = list_entry(list.next, struct nfs_write_data, pages);
|
data = list_entry(list.next, struct nfs_write_data, pages);
|
||||||
list_del(&data->pages);
|
list_del(&data->pages);
|
||||||
nfs_writedata_release(data);
|
nfs_writedata_free(data);
|
||||||
}
|
}
|
||||||
nfs_redirty_request(req);
|
nfs_redirty_request(req);
|
||||||
return -ENOMEM;
|
return -ENOMEM;
|
||||||
|
Reference in New Issue
Block a user