summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMax Kellermann <max@musicpd.org>2019-02-19 12:51:24 +0100
committerMax Kellermann <max@musicpd.org>2019-02-19 12:51:24 +0100
commit57633fbcb3c9b91c7c906e43b9479084c6d76f16 (patch)
tree86c72f101654c6dd1b3ec26d4aa538c948ec2d15 /src
parent864c87e6c05de13f221413b5a581d4d569495e2b (diff)
net/AllocatedSocketAddress: add methods IsV6Any(), IsV4Mapped()
Diffstat (limited to 'src')
-rw-r--r--src/net/AllocatedSocketAddress.hxx8
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.
*/