aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMartin Willi <martin@strongswan.org>2009-03-19 09:04:20 +0000
committerMartin Willi <martin@strongswan.org>2009-03-19 09:04:20 +0000
commitce67ab162d4bb973c5974f6bab302d6af9777b15 (patch)
treea2d695801f43b38dc23853edd8fada53a37203b5
parentc5c969639c0562c7fb1cf56409636441f2d543b3 (diff)
downloadstrongswan-ce67ab162d4bb973c5974f6bab302d6af9777b15.tar.bz2
strongswan-ce67ab162d4bb973c5974f6bab302d6af9777b15.tar.xz
print IPv6 %any hosts as %any6
-rw-r--r--src/libstrongswan/utils/host.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/libstrongswan/utils/host.c b/src/libstrongswan/utils/host.c
index e11017c1e..6a6a49089 100644
--- a/src/libstrongswan/utils/host.c
+++ b/src/libstrongswan/utils/host.c
@@ -119,7 +119,8 @@ int host_printf_hook(char *dst, size_t dstlen, printf_hook_spec_t *spec,
}
else if (is_anyaddr(this))
{
- snprintf(buffer, sizeof(buffer), "%%any");
+ snprintf(buffer, sizeof(buffer), "%%any%s",
+ this->address.sa_family == AF_INET6 ? "6" : "");
}
else
{