]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
false use-after-move on store 58293/head
authorSuyash Dongre <suyashd999@gmail.com>
Wed, 26 Jun 2024 17:51:42 +0000 (23:21 +0530)
committerSuyash Dongre <suyashd999@gmail.com>
Sat, 31 Aug 2024 20:56:33 +0000 (02:26 +0530)
Fixes: https://tracker.ceph.com/issues/66709
Signed-off-by: Suyash Dongre <suyashd999@gmail.com>
src/ceph_osd.cc
src/common/Preforker.h

index c0bd5b33ad4e47037de5a095414c92586e2af564..52988843c8327c186dce932dc0703aa3d3d2d9a2 100644 (file)
@@ -375,8 +375,9 @@ int main(int argc, const char **argv)
            << " for osd." << whoami
            << " fsid " << g_conf().get_val<uuid_d>("fsid")
            << dendl;
+    forker.exit(0);
   }
-  if (mkfs || mkkey) {
+  if (mkkey) {
     forker.exit(0);
   }
   if (mkjournal) {
index d34179b40204a71099933702b8dbe9aaeb8908d2..d25d5dd5adae0afb7a855889ccd03c6c01541213 100644 (file)
@@ -126,7 +126,7 @@ public:
     }
     return r;
   }
-  void exit(int r) {
+  [[noreturn]] void exit(int r) {
     if (is_child())
         signal_exit(r);
     ::exit(r);