on second thought make it a new param force-subscription-domain

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@14971 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
Anthony Minessale 2009-09-24 22:29:52 +00:00
parent db8a82793b
commit 019ee96464
3 changed files with 5 additions and 2 deletions

View File

@ -434,6 +434,7 @@ struct sofia_profile {
char *tls_bind_params;
char *tls_cert_dir;
char *reg_domain;
char *sub_domain;
char *reg_db_domain;
char *user_agent;
char *record_template;

View File

@ -1893,6 +1893,8 @@ switch_status_t reconfig_sofia(sofia_profile_t *profile)
profile->local_network = switch_core_strdup(profile->pool, val);
} else if (!strcasecmp(var, "force-register-domain")) {
profile->reg_domain = switch_core_strdup(profile->pool, val);
} else if (!strcasecmp(var, "force-subscription-domain")) {
profile->sub_domain = switch_core_strdup(profile->pool, val);
} else if (!strcasecmp(var, "force-register-db-domain")) {
profile->reg_db_domain = switch_core_strdup(profile->pool, val);
} else if (!strcasecmp(var, "hold-music")) {

View File

@ -1552,8 +1552,8 @@ void sofia_presence_handle_sip_i_subscribe(int status,
to_host = to->a_url->url_host;
}
if (profile->reg_db_domain) {
to_host = profile->reg_db_domain;
if (profile->sub_domain) {
to_host = profile->sub_domain;
}
if (sip && sip->sip_from) {