diff options
author | Max Kellermann <max@musicpd.org> | 2019-02-19 12:51:24 +0100 |
---|---|---|
committer | Max Kellermann <max@musicpd.org> | 2019-02-19 12:51:24 +0100 |
commit | 57633fbcb3c9b91c7c906e43b9479084c6d76f16 (patch) | |
tree | 86c72f101654c6dd1b3ec26d4aa538c948ec2d15 /src/net | |
parent | 864c87e6c05de13f221413b5a581d4d569495e2b (diff) |
net/AllocatedSocketAddress: add methods IsV6Any(), IsV4Mapped()
Diffstat (limited to 'src/net')
-rw-r--r-- | src/net/AllocatedSocketAddress.hxx | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/net/AllocatedSocketAddress.hxx b/src/net/AllocatedSocketAddress.hxx index 62a9ffba6..f662f89ad 100644 --- a/src/net/AllocatedSocketAddress.hxx +++ b/src/net/AllocatedSocketAddress.hxx @@ -163,6 +163,14 @@ public: #endif #ifdef HAVE_TCP + bool IsV6Any() const noexcept { + return ((SocketAddress)*this).IsV6Any(); + } + + bool IsV4Mapped() const noexcept { + return ((SocketAddress)*this).IsV4Mapped(); + } + /** * Extract the port number. Returns 0 if not applicable. */ |