]> git.proxmox.com Git - ceph.git/blobdiff - ceph/src/log/Entry.h
update sources to v12.2.5
[ceph.git] / ceph / src / log / Entry.h
index 7e2f83401ae6120f3425f3f40c7d14701a98f10b..bbcd17988b2ed410a75f93850d687bfe74f38620 100644 (file)
@@ -58,6 +58,10 @@ struct Entry {
     }
   }
 
+private:
+  ~Entry() = default;
+
+public:
   // function improves estimate for expected size of message
   void hint_size() {
     if (m_exp_len != NULL) {
@@ -91,6 +95,15 @@ struct Entry {
   int snprintf(char* dst, size_t avail) const {
     return m_streambuf.snprintf(dst, avail);
   }
+
+  void destroy() {
+    if (m_exp_len != NULL) {
+      this->~Entry();
+      ::operator delete(this);
+    } else {
+      delete(this);
+    }
+  }
 };
 
 }