From e535e2efd295c3990bb9f654c8bb6bd176ebdc2b Mon Sep 17 00:00:00 2001 From: Mark Fasheh Date: Fri, 31 Aug 2007 10:23:41 -0700 Subject: ocfs2: Fix calculation of i_blocks during truncate We were setting i_blocks too early - before truncating any allocation. Correct things to set i_blocks after the allocation change. Signed-off-by: Mark Fasheh --- fs/ocfs2/file.c | 1 - 1 file changed, 1 deletion(-) (limited to 'fs/ocfs2/file.c') diff --git a/fs/ocfs2/file.c b/fs/ocfs2/file.c index 4ffa715be09..7e34e66159c 100644 --- a/fs/ocfs2/file.c +++ b/fs/ocfs2/file.c @@ -314,7 +314,6 @@ static int ocfs2_orphan_for_truncate(struct ocfs2_super *osb, } i_size_write(inode, new_i_size); - inode->i_blocks = ocfs2_align_bytes_to_sectors(new_i_size); inode->i_ctime = inode->i_mtime = CURRENT_TIME; di = (struct ocfs2_dinode *) fe_bh->b_data; -- cgit v1.2.3