Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
plug some leak by delete last message before leaving
[simgrid.git] / examples / s4u / dht-chord / s4u_dht-chord.hpp
index 3e7cf06..095ea8c 100644 (file)
@@ -156,7 +156,9 @@ public:
       }
       now = simgrid::s4u::Engine::instance()->getClock();
     }
       }
       now = simgrid::s4u::Engine::instance()->getClock();
     }
-
+    if (data != nullptr) {
+      delete static_cast<ChordMessage*>(data);
+    }
     // leave the ring
     leave();
   }
     // leave the ring
     leave();
   }