aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/libstrongswan/utils/host.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libstrongswan/utils/host.c b/src/libstrongswan/utils/host.c
index b60d532c7..bc31f22e0 100644
--- a/src/libstrongswan/utils/host.c
+++ b/src/libstrongswan/utils/host.c
@@ -480,7 +480,7 @@ host_t *host_create_from_dns(char *string, int af, u_int16_t port)
}
this = host_create_empty();
this->address.sa_family = host.h_addrtype;
- switch (af)
+ switch (this->address.sa_family)
{
case AF_INET:
memcpy(&this->address4.sin_addr.s_addr,