]> git.apps.os.sepia.ceph.com Git - xfsprogs-dev.git/commit
xfs_repair: don't leak the rootdir inode when orphanage already exists
authorDarrick J. Wong <djwong@kernel.org>
Mon, 29 Jul 2024 23:22:33 +0000 (16:22 -0700)
committerDarrick J. Wong <djwong@kernel.org>
Tue, 30 Jul 2024 00:00:59 +0000 (17:00 -0700)
commitb67a805cf877525ce74031832a07f6359c04cc9b
tree8a8864596aff9a8efd30f19108f132a727c8bacd
parent794f60a6ca5d7281d7cbabe4f3fffb0494557765
xfs_repair: don't leak the rootdir inode when orphanage already exists

If repair calls mk_orphanage and the /lost+found directory already
exists, we need to irele the root directory before exiting the function.

Fixes: 6c39a3cbda32 ("Don't trash lost+found in phase 4 Merge of master-melb:xfs-cmds:29144a by kenmcd.")
Signed-off-by: Darrick J. Wong <djwong@kernel.org>
Reviewed-by: Christoph Hellwig <hch@lst.de>
repair/phase6.c