]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
osd: remove invalid put on message 47525/head
authorNitzanMordhai <nmordech@redhat.com>
Sun, 24 Jul 2022 08:00:07 +0000 (08:00 +0000)
committerNitzan Mordechai <nmordech@redhat.com>
Wed, 10 Aug 2022 05:56:22 +0000 (08:56 +0300)
message converted to use smart pointer, the put is extra step that
causing the double put and valgrind error
the regression was introduced by d4a71c3

Fixes: https://tracker.ceph.com/issues/52124
Signed-off-by: Nitzan Mordechai <nmordec@redhat.com>
(cherry picked from commit c449638812daeafa89c592b9c396eaa66327f85f)

src/osd/PGBackend.cc
src/osd/PrimaryLogPG.h

index b6357b12639a9054cef56cc2d38771cc45ecd22d..ef2eb538171601fb8569d6746ce34d2446c2d0e2 100644 (file)
@@ -156,8 +156,6 @@ void PGBackend::handle_recovery_delete(OpRequestRef op)
     [=](int r) {
       if (r != -EAGAIN) {
        get_parent()->send_message_osd_cluster(reply, conn.get());
-      } else {
-       reply->put();
       }
     }));
   gather.activate();
index 358061acbe1c2965fe5ec8cebb45bb6e5e123cdb..68cdec24e38ed780aa9d0b6453891289ae9fcbc9 100644 (file)
@@ -557,7 +557,7 @@ public:
   }
   void send_message_osd_cluster(
     MessageRef m, Connection *con) override {
-    osd->send_message_osd_cluster(m, con);
+    osd->send_message_osd_cluster(std::move(m), con);
   }
   void send_message_osd_cluster(
     Message *m, const ConnectionRef& con) override {