diff --git a/source/common/network/socket_option_impl.h b/source/common/network/socket_option_impl.h index 4fa210738bef..1a13a67010cb 100644 --- a/source/common/network/socket_option_impl.h +++ b/source/common/network/socket_option_impl.h @@ -105,7 +105,7 @@ class SocketOptionImpl : public Socket::Option, Logger::Loggable(value_.data()) % alignof(std::max_align_t) == 0); + ASSERT(reinterpret_cast(value_.data()) % alignof(void*) == 0); } // Socket::Option @@ -138,7 +138,7 @@ class SocketOptionImpl : public Socket::Option, Logger::Loggable but not std::string because std::string might inline - // the buffer so its data() is not aligned in to alignof(std::max_align_t). + // the buffer so its data() is not aligned in to alignof(void*). const std::vector value_; };