[2.4.5]Patch - fix page leak in nfs_prepare_write()
Hi,
The following patch fixes a leak in high memory in case a
process is signalled while in nfs_prepare_write().
Cheers,
Trond
fs/nfs/file.c +10 -1
@@ -162,9 +162,18 @@*/ static int nfs_prepare_write (struct file *file,struct page *page,unsigned offset,unsigned to) { +int status; +kmap (page); -return nfs_flush_incompatible (file, page); + status =nfs_flush_incompatible (file, page); +if (status) + goto out_err; +return 0 ; + out_err: +kunmap (page); +return status; } +static int nfs_commit_write (struct file *file,struct page *page,unsigned offset,unsigned to) {long status;