[Freeswitch-svn] [commit] r7642 - freeswitch/trunk/src/mod/endpoints/mod_sofia
Freeswitch SVN
brian at freeswitch.org
Fri Feb 15 18:18:19 EST 2008
Author: brian
Date: Fri Feb 15 18:18:18 2008
New Revision: 7642
Modified:
freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia.c
freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia_glue.c
freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia_presence.c
Log:
to be or not to be
Modified: freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia.c
==============================================================================
--- freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia.c (original)
+++ freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia.c Fri Feb 15 18:18:18 2008
@@ -1936,10 +1936,10 @@
new_b_session = switch_core_session_locate(br_b);
a_session = switch_core_session_locate(br_a);
sofia_info_send_sipfrag(a_session, new_b_session);
- if(new_b_session) {
+ if (new_b_session) {
switch_core_session_rwunlock(new_b_session);
}
- if(a_session) {
+ if (a_session) {
switch_core_session_rwunlock(a_session);
}
//switch_channel_hangup(channel_b, SWITCH_CAUSE_ATTENDED_TRANSFER);
@@ -2195,7 +2195,7 @@
}
if ((clientcode_header = sofia_glue_get_unknown_header(sip, "x-clientcode"))) {
- if(!switch_strlen_zero(clientcode_header)) {
+ if (!switch_strlen_zero(clientcode_header)) {
switch_channel_set_variable(channel, "call_clientcode", clientcode_header);
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_NOTICE, "Setting CMC to %s\n", clientcode_header);
nua_respond(nh, SIP_200_OK, NUTAG_WITH_THIS(nua), TAG_END());
@@ -2256,7 +2256,7 @@
user = url->url_user;
host = url->url_host;
port = url->url_port;
- if(!switch_strlen_zero(url->url_params)) {
+ if (!switch_strlen_zero(url->url_params)) {
switch_channel_set_variable(channel, params_var, url->url_params);
}
}
@@ -2809,7 +2809,7 @@
if (b_tech_pvt && a_tech_pvt && a_tech_pvt->caller_profile) {
switch_caller_profile_t *acp = a_tech_pvt->caller_profile;
- if(switch_strlen_zero(acp->caller_id_name)) {
+ if (switch_strlen_zero(acp->caller_id_name)) {
snprintf(message, sizeof(message), "From:\r\nTo: %s\r\n", acp->caller_id_number);
} else {
snprintf(message, sizeof(message), "From:\r\nTo: \"%s\" %s\r\n", acp->caller_id_name, acp->caller_id_number);
Modified: freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia_glue.c
==============================================================================
--- freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia_glue.c (original)
+++ freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia_glue.c Fri Feb 15 18:18:18 2008
@@ -580,7 +580,7 @@
char *ptr = NULL;
int tls = 0;
- if(!url)
+ if (!url)
return SOFIA_TRANSPORT_UNKNOWN;
if (url->url_scheme && !strcasecmp(url->url_scheme, "sips")) {
@@ -612,13 +612,13 @@
if (!strncasecmp(ptr, "udp", 3)) {
return SOFIA_TRANSPORT_UDP;
}
- else if(!strncasecmp(ptr, "tcp", 3)) {
+ else if (!strncasecmp(ptr, "tcp", 3)) {
return SOFIA_TRANSPORT_TCP;
}
- else if(!strncasecmp(ptr, "tls", 3)) {
+ else if (!strncasecmp(ptr, "tls", 3)) {
return SOFIA_TRANSPORT_TCP_TLS;
}
- else if(!strncasecmp(ptr, "sctp", 4)) {
+ else if (!strncasecmp(ptr, "sctp", 4)) {
return SOFIA_TRANSPORT_SCTP;
}
}
Modified: freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia_presence.c
==============================================================================
--- freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia_presence.c (original)
+++ freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia_presence.c Fri Feb 15 18:18:18 2008
@@ -743,7 +743,7 @@
clean_from_user = switch_mprintf("%s", from_id ? from_id : from_user);
if (is_dialog) {
- if(!switch_strlen_zero(clean_to_user) && !switch_strlen_zero(clean_from_user)) {
+ if (!switch_strlen_zero(clean_to_user) && !switch_strlen_zero(clean_from_user)) {
stream.write_function(&stream, "<local>\n<identity display=\"%s\">sip:%s@%s</identity>\n", clean_to_user, clean_to_user, host);
stream.write_function(&stream, "<target uri=\"sip:%s@%s\">\n", clean_to_user, host);
stream.write_function(&stream, "<param pname=\"+sip.rendering\" pvalue=\"%s\"/>\n", !strcasecmp(event_status, "hold") ? "no" : "yes" );
More information about the Freeswitch-svn
mailing list