diff --git a/src/server/network/message/outputmessage.cpp b/src/server/network/message/outputmessage.cpp index 68daee2afd9..293cdee0d95 100644 --- a/src/server/network/message/outputmessage.cpp +++ b/src/server/network/message/outputmessage.cpp @@ -66,7 +66,7 @@ OutputMessage_ptr OutputMessagePool::getOutputMessage() { } return { rawPtr, [&allocator](OutputMessage*&ptr) mutable { - if (ptr) { + if (ptr != nullptr) { ptr->~OutputMessage(); allocator.deallocate(ptr, 1); }