]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
crimson/os/seastore: s/assert/ceph_abort_msg/ when hitting unreachable code 35914/head
authorKefu Chai <kchai@redhat.com>
Fri, 3 Jul 2020 09:35:48 +0000 (17:35 +0800)
committerKefu Chai <kchai@redhat.com>
Fri, 3 Jul 2020 16:17:38 +0000 (00:17 +0800)
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 <kchai@redhat.com>
src/crimson/os/seastore/root_block.h

index acc31eefe954a2e00b0772d3aa25d7bb4b25ab56..9a9a58c5b0129f44112fc1113e473e55679ff7fa 100644 (file)
@@ -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; }