Files
Jan Kara 33c5063fd1 ext3: Fix fdatasync() for files with only i_size changes
commit 156bddd8e5 upstream.

Code tracking when transaction needs to be committed on fdatasync(2) forgets
to handle a situation when only inode's i_size is changed. Thus in such
situations fdatasync(2) doesn't force transaction with new i_size to disk
and that can result in wrong i_size after a crash.

Fix the issue by updating inode's i_datasync_tid whenever its size is
updated.

Reported-by: Kristian Nielsen <knielsen@knielsen-hq.org>
Signed-off-by: Jan Kara <jack@suse.cz>
[bwh: Backported to 3.2: adjust context]
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
2012-09-19 15:04:37 +01:00
..
2011-07-25 14:30:23 -04:00
2011-11-02 12:53:43 +01:00
2011-03-31 11:26:23 -03:00
2011-08-17 11:42:19 +02:00