]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commit
osd/OSD: use scope_guard to umount objecstore
authorKefu Chai <kchai@redhat.com>
Tue, 25 May 2021 07:41:26 +0000 (15:41 +0800)
committerKefu Chai <kchai@redhat.com>
Thu, 27 May 2021 15:07:10 +0000 (23:07 +0800)
commit8b2c3a211a84904dc0307eed7267f5687c13dc74
tree4e4972ff3afbf42a4493bdc8e44e21c4e2a5060d
parent3f659a48275bb70939f23f5c40a0b2ef983fc38b
osd/OSD: use scope_guard to umount objecstore

RAII can simplify the clean up logic in OSD::mkfs().

and since `ch` is a smart pointer, so it is able to take care of itself,
as long as we ensure that it is destructed before objectstore.

Signed-off-by: Kefu Chai <kchai@redhat.com>
src/osd/OSD.cc