Merge pull request #812 in FS/freeswitch from ~GIAVAC/freeswitch:FS-9083 to master
* commit '252f0e2618493aeba3b29bccfd0ecb9d04ff3473': FS-9083 [mod-sofia] Pass On SIP headers from leg A to B
This commit is contained in:
commit
312df1fbed
|
@ -10558,7 +10558,7 @@ void sofia_handle_sip_i_invite(switch_core_session_t *session, nua_t *nua, sofia
|
|||
switch_channel_set_variable(channel, "sip_geolocation_error", un->un_value);
|
||||
} else if (!strcasecmp(un->un_name, "userLocation")) {
|
||||
switch_channel_set_variable(channel, "sip_user_location", un->un_value);
|
||||
} else if (!strncasecmp(un->un_name, "X-", 2) || !strncasecmp(un->un_name, "P-", 2) || !strcasecmp(un->un_name, "User-to-User")) {
|
||||
} else if (!strncasecmp(un->un_name, "X-", 2) || !strncasecmp(un->un_name, "P-", 2) || !strcasecmp(un->un_name, "User-to-User") || !strncasecmp(un->un_name, "On", 2)) {
|
||||
if (!zstr(un->un_value)) {
|
||||
char new_name[512] = "";
|
||||
int reps = 0;
|
||||
|
|
|
@ -644,7 +644,7 @@ void sofia_glue_set_extra_headers(switch_core_session_t *session, sip_t const *s
|
|||
}
|
||||
|
||||
for (un = sip->sip_unknown; un; un = un->un_next) {
|
||||
if ((!strncasecmp(un->un_name, "X-", 2) && strncasecmp(un->un_name, "X-FS-", 5)) || !strncasecmp(un->un_name, "P-", 2)) {
|
||||
if ((!strncasecmp(un->un_name, "X-", 2) && strncasecmp(un->un_name, "X-FS-", 5)) || !strncasecmp(un->un_name, "P-", 2) || !strncasecmp(un->un_name, "On", 2)) {
|
||||
if (!zstr(un->un_value)) {
|
||||
switch_snprintf(name, sizeof(name), "%s%s", prefix, un->un_name);
|
||||
switch_channel_set_variable(channel, name, un->un_value);
|
||||
|
|
Loading…
Reference in New Issue