From: Trond Myklebust Date: Tue, 19 Sep 2006 03:20:35 +0000 (-0400) Subject: NFS: Fix nfs_page use after free issues in fs/nfs/write.c X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=5c2d97cb31fb77981797fec46230ca005b865799;p=GitHub%2Fexynos8895%2Fandroid_kernel_samsung_universal8895.git NFS: Fix nfs_page use after free issues in fs/nfs/write.c Signed-off-by: Trond Myklebust --- diff --git a/fs/nfs/write.c b/fs/nfs/write.c index 8ab3cf10d792..7084ac9a6455 100644 --- a/fs/nfs/write.c +++ b/fs/nfs/write.c @@ -590,8 +590,8 @@ static void nfs_cancel_commit_list(struct list_head *head) req = nfs_list_entry(head->next); nfs_list_remove_request(req); nfs_inode_remove_request(req); - nfs_clear_page_writeback(req); dec_zone_page_state(req->wb_page, NR_UNSTABLE_NFS); + nfs_clear_page_writeback(req); } } @@ -1386,8 +1386,8 @@ nfs_commit_list(struct inode *inode, struct list_head *head, int how) req = nfs_list_entry(head->next); nfs_list_remove_request(req); nfs_mark_request_commit(req); - nfs_clear_page_writeback(req); dec_zone_page_state(req->wb_page, NR_UNSTABLE_NFS); + nfs_clear_page_writeback(req); } return -ENOMEM; }