ext4: Handle non empty on-disk orphan link
authorDmitry Monakhov <dmonakhov@openvz.org>
Tue, 2 Mar 2010 04:29:39 +0000 (23:29 -0500)
committerMatt Sealey <matt@genesi-usa.com>
Mon, 29 Nov 2010 23:08:29 +0000 (17:08 -0600)
commit618ef6e62cd5795cc8a07a94fa1ae553ce10850e
tree89bc7ad78227dc28d754afde481e1da75627e48e
parentd016695d8e6d654b7d0129d09748f9695cd757e4
ext4: Handle non empty on-disk orphan link

In case of truncate errors we explicitly remove inode from in-core
orphan list via orphan_del(NULL, inode) without modifying the on-disk list.

But later on, the same inode may be inserted in the orphan list again
which will result the on-disk linked list getting corrupted.  If inode
i_dtime contains valid value, then skip on-disk list modification.

Signed-off-by: Dmitry Monakhov <dmonakhov@openvz.org>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
fs/ext4/namei.c