summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
author4-FLOSS-Free-Libre-Open-Source-Software <46166740+4-FLOSS-Free-Libre-Open-Source-Software@users.noreply.github.com>2019-08-01 22:13:59 +0200
committerGitHub <noreply@github.com>2019-08-01 22:13:59 +0200
commita5b81c715d331ef2c799eaf20c10e384355c5667 (patch)
treea139f87aad731b7f21c3cf59323392553a21d303 /src
parent05082ae12051821b1d969e6672d9e4e5afe1bc07 (diff)
downloadtwinkle-a5b81c715d331ef2c799eaf20c10e384355c5667.tar
twinkle-a5b81c715d331ef2c799eaf20c10e384355c5667.tar.gz
twinkle-a5b81c715d331ef2c799eaf20c10e384355c5667.tar.lz
twinkle-a5b81c715d331ef2c799eaf20c10e384355c5667.tar.xz
twinkle-a5b81c715d331ef2c799eaf20c10e384355c5667.zip
resolve nat_public_ip hostname for dyndns to work
Diffstat (limited to 'src')
-rw-r--r--src/phone_user.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/phone_user.cpp b/src/phone_user.cpp
index c52f396..632d07b 100644
--- a/src/phone_user.cpp
+++ b/src/phone_user.cpp
@@ -1499,7 +1499,7 @@ bool t_phone_user::get_last_reg_failed(void) const {
string t_phone_user::get_ip_sip(const string &auto_ip) const {
if (stun_public_ip_sip) return h_ip2str(stun_public_ip_sip);
- if (user_config->get_use_nat_public_ip()) return user_config->get_nat_public_ip();
+ if (user_config->get_use_nat_public_ip()) return h_ip2str(gethostbyname(user_config->get_nat_public_ip()));
if (LOCAL_IP == AUTO_IP4_ADDRESS) return auto_ip;
return LOCAL_IP;
}