fix(Proxy): remove useless affectation on linphone_nat_policy_ref return

This commit is contained in:
Ronan Abhamon 2018-02-21 14:13:07 +01:00 committed by Simon Morlat
parent 6a5190d947
commit 1cadac2187

View file

@ -1538,7 +1538,7 @@ LinphoneNatPolicy * linphone_proxy_config_get_nat_policy(const LinphoneProxyConf
void linphone_proxy_config_set_nat_policy(LinphoneProxyConfig *cfg, LinphoneNatPolicy *policy) {
if (policy != NULL) {
policy = linphone_nat_policy_ref(policy); /* Prevent object destruction if the same policy is used */
linphone_nat_policy_ref(policy); /* Prevent object destruction if the same policy is used */
policy->lc = cfg->lc;
}
if (cfg->nat_policy != NULL) linphone_nat_policy_unref(cfg->nat_policy);