Files
linux/fs/ocfs2
Joseph Qi 28f4821b1b ocfs2: clear dinode links count in case of error
In ocfs2_mknod(), if error occurs after dinode successfully allocated,
ocfs2 i_links_count will not be 0.

So even though we clear inode i_nlink before iput in error handling, it
still won't wipe inode since we'll refresh inode from dinode during inode
lock.  So just like clear inode i_nlink, we clear ocfs2 i_links_count as
well.  Also do the same change for ocfs2_symlink().

Link: https://lkml.kernel.org/r/[email protected]
Signed-off-by: Joseph Qi <[email protected]>
Reported-by: Yan Wang <[email protected]>
Cc: Mark Fasheh <[email protected]>
Cc: Joel Becker <[email protected]>
Cc: Junxiao Bi <[email protected]>
Cc: Changwei Ge <[email protected]>
Cc: Gang He <[email protected]>
Cc: Jun Piao <[email protected]>
Cc: <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
2022-10-20 21:27:22 -07:00
..
2022-05-09 16:21:46 -04:00
2022-09-11 20:26:07 -07:00
2022-08-17 17:25:04 -04:00
2022-07-29 18:12:36 -07:00
2021-04-12 15:04:30 +02:00
2018-12-28 12:11:45 -08:00
…
…
2022-05-09 16:21:46 -04:00