From: Kefu Chai Date: Fri, 3 Jul 2020 09:35:48 +0000 (+0800) Subject: crimson/os/seastore: s/assert/ceph_abort_msg/ when hitting unreachable code X-Git-Tag: wip-pdonnell-testing-20200918.022351~761^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=3bb47bc41c409d8d3a3b06325be093f74237bce7;p=ceph-ci.git crimson/os/seastore: s/assert/ceph_abort_msg/ when hitting unreachable code clang++ complains with ``` crimson/os/seastore/root_block.h:100:3: warning: control reaches end of non-void function [-Wreturn-type] } ^ ``` Signed-off-by: Kefu Chai --- diff --git a/src/crimson/os/seastore/root_block.h b/src/crimson/os/seastore/root_block.h index acc31eefe95..9a9a58c5b01 100644 --- a/src/crimson/os/seastore/root_block.h +++ b/src/crimson/os/seastore/root_block.h @@ -96,11 +96,11 @@ struct RootBlock : CachedExtent { } complete_load_ertr::future<> complete_load() final { - assert(0 == "Root is only written via deltas"); + ceph_abort_msg("Root is only written via deltas"); } void on_initial_write() final { - assert(0 == "Root is only written via deltas"); + ceph_abort_msg("Root is only written via deltas"); } root_t &get_lba_root() { return root; }