diff --git a/lib/include/srsran/adt/pool/pool_interface.h b/lib/include/srsran/adt/pool/pool_interface.h index ba9e8771b..f2007fd3a 100644 --- a/lib/include/srsran/adt/pool/pool_interface.h +++ b/lib/include/srsran/adt/pool/pool_interface.h @@ -27,10 +27,8 @@ public: explicit pool_deallocator(obj_pool_itf* pool_ = nullptr) : pool(pool_) {} void operator()(void* ptr) { - if (ptr != nullptr) { - static_cast(ptr)->~T(); - pool->do_deallocate(ptr); - } + // dtor is not called, as object is going to be recycled + pool->do_deallocate(ptr); } }; using object_type = T;