Skip to content

Commit f294d3e

Browse files
Eric Sandeenjankara
authored andcommitted
ext3: explicitly remove inode from orphan list after failed direct io
Otherwise non-empty orphan list will be triggered on umount. This is just an application of commit da1daf by Dmitry Monakhov to the same code in ext3. Signed-off-by: Eric Sandeen <sandeen@redhat.com> Signed-off-by: Jan Kara <jack@suse.cz>
1 parent b3b749b commit f294d3e

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

‎fs/ext3/inode.c‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1883,6 +1883,8 @@ static ssize_t ext3_direct_IO(int rw, struct kiocb *iocb,
18831883
* and pretend the write failed... */
18841884
ext3_truncate_failed_direct_write(inode);
18851885
ret = PTR_ERR(handle);
1886+
if (inode->i_nlink)
1887+
ext3_orphan_del(NULL, inode);
18861888
goto out;
18871889
}
18881890
if (inode->i_nlink)

0 commit comments

Comments
 (0)