net/SocketAddress: add IsV4Mapped()

This commit is contained in:
Max Kellermann
2018-08-21 10:43:36 +02:00
parent 94092f1f90
commit dfc1f6342a
3 changed files with 14 additions and 13 deletions

View File

@@ -114,6 +114,12 @@ public:
gcc_pure
bool IsV6Any() const noexcept;
/**
* Is this an IPv4 address mapped inside struct sockaddr_in6?
*/
gcc_pure
bool IsV4Mapped() const noexcept;
/**
* Extract the port number. Returns 0 if not applicable.
*/