diff options
Diffstat (limited to 'fs/buffer.c')
-rw-r--r-- | fs/buffer.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/buffer.c b/fs/buffer.c index ba02c8be1..20790847f 100644 --- a/fs/buffer.c +++ b/fs/buffer.c @@ -1620,9 +1620,9 @@ int cont_prepare_write(struct page *page, unsigned offset, unsigned to, get_bloc PAGE_CACHE_SIZE, get_block); if (status) goto out_unmap; - kaddr = (char*)page_address(page); + kaddr = (char*)page_address(new_page); memset(kaddr+zerofrom, 0, PAGE_CACHE_SIZE-zerofrom); - __block_commit_write(inode, new_page, zerofrom, to); + __block_commit_write(inode, new_page, zerofrom, PAGE_CACHE_SIZE); kunmap(new_page); UnlockPage(new_page); page_cache_release(new_page); |