提交 f294d3e7 编写于 作者: E Eric Sandeen 提交者: Jan Kara

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: NEric Sandeen <sandeen@redhat.com>
Signed-off-by: NJan Kara <jack@suse.cz>
上级 b3b749b7
...@@ -1883,6 +1883,8 @@ static ssize_t ext3_direct_IO(int rw, struct kiocb *iocb, ...@@ -1883,6 +1883,8 @@ static ssize_t ext3_direct_IO(int rw, struct kiocb *iocb,
* and pretend the write failed... */ * and pretend the write failed... */
ext3_truncate_failed_direct_write(inode); ext3_truncate_failed_direct_write(inode);
ret = PTR_ERR(handle); ret = PTR_ERR(handle);
if (inode->i_nlink)
ext3_orphan_del(NULL, inode);
goto out; goto out;
} }
if (inode->i_nlink) if (inode->i_nlink)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册