diff --git a/src/net/IPv4Address.hxx b/src/net/IPv4Address.hxx index 7e6ee79f4..e57bdf4cf 100644 --- a/src/net/IPv4Address.hxx +++ b/src/net/IPv4Address.hxx @@ -172,7 +172,7 @@ public: * Return a downcasted reference to the address. This call is * only legal after verifying SocketAddress::GetFamily(). */ - static constexpr const IPv4Address &Cast(const SocketAddress src) noexcept { + static constexpr const IPv4Address &Cast(const SocketAddress &src) noexcept { /* this reinterpret_cast works because this class is just a wrapper for struct sockaddr_in6 */ return *(const IPv4Address *)(const void *)src.GetAddress();