ike: Use proper hostname(s) when name resolution failed
[strongswan.git] / src / libcharon / sa / ike_sa.c
index 000e68f..9d417ad 100644 (file)
@@ -1174,7 +1174,7 @@ METHOD(ike_sa_t, initiate, status_t,
                        host_t *host;
                        char *addr;
 
-                       addr = this->ike_cfg->get_my_addr(this->ike_cfg);
+                       addr = this->ike_cfg->get_other_addr(this->ike_cfg);
                        host = this->ike_cfg->resolve_other(this->ike_cfg, AF_UNSPEC);
                        is_anyaddr = host && host->is_anyaddr(host);
                        DESTROY_IF(host);