[Freeswitch-svn] [commit] r8766 - in freeswitch/trunk/libs/sofia-sip: . libsofia-sip-ua/nua
Freeswitch SVN
mikej at freeswitch.org
Thu Jun 5 12:20:01 EDT 2008
Author: mikej
Date: Thu Jun 5 12:20:01 2008
New Revision: 8766
Modified:
freeswitch/trunk/libs/sofia-sip/.update
freeswitch/trunk/libs/sofia-sip/libsofia-sip-ua/nua/nua_session.c
Log:
Thu Jun 5 11:32:08 EDT 2008 Pekka Pessi <first.last at nokia.com>
* nua_session.c: sanitized asserts with dialog usage for SIP session
Modified: freeswitch/trunk/libs/sofia-sip/.update
==============================================================================
--- freeswitch/trunk/libs/sofia-sip/.update (original)
+++ freeswitch/trunk/libs/sofia-sip/.update Thu Jun 5 12:20:01 2008
@@ -1 +1 @@
-Tue Jun 3 14:56:27 EDT 2008
+Thu Jun 5 12:19:53 EDT 2008
Modified: freeswitch/trunk/libs/sofia-sip/libsofia-sip-ua/nua/nua_session.c
==============================================================================
--- freeswitch/trunk/libs/sofia-sip/libsofia-sip-ua/nua/nua_session.c (original)
+++ freeswitch/trunk/libs/sofia-sip/libsofia-sip-ua/nua/nua_session.c Thu Jun 5 12:20:01 2008
@@ -761,18 +761,18 @@
{
nua_handle_t *nh = cr->cr_owner;
nua_dialog_usage_t *du = cr->cr_usage;
- nua_session_usage_t *ss = nua_dialog_usage_private(du);
+ nua_session_usage_t *ss;
int offer_sent = 0, retval;
sip_time_t invite_timeout;
if (du == NULL) /* Call terminated */
return nua_client_return(cr, SIP_481_NO_TRANSACTION, msg);
+ ss = NUA_DIALOG_USAGE_PRIVATE(du);
+
if (ss->ss_state >= nua_callstate_terminating)
return nua_client_return(cr, 900, "Session is terminating", msg);
- assert(ss);
-
invite_timeout = NH_PGET(nh, invite_timeout);
if (invite_timeout == 0)
invite_timeout = UINT_MAX;
@@ -868,7 +868,7 @@
nua_dialog_usage_t *du = cr->cr_usage;
nua_session_usage_t *ss = nua_dialog_usage_private(du);
- assert(sip); assert(ss);
+ assert(sip);
if (ss && sip && sip->sip_rseq) {
/* Handle 100rel responses */
@@ -1683,7 +1683,7 @@
{
nua_handle_t *nh = cr->cr_owner;
nua_dialog_usage_t *du = cr->cr_usage;
- nua_session_usage_t *ss = nua_dialog_usage_private(du);
+ nua_session_usage_t *ss;
nua_client_request_t *cri;
int offer_sent = 0, answer_sent = 0, retval;
int status = 0; char const *phrase = "PRACK Sent";
@@ -1691,7 +1691,8 @@
if (du == NULL) /* Call terminated */
return nua_client_return(cr, SIP_481_NO_TRANSACTION, msg);
- assert(ss);
+
+ ss = NUA_DIALOG_USAGE_PRIVATE(du);
if (ss->ss_state >= nua_callstate_terminating)
return nua_client_return(cr, 900, "Session is terminating", msg);
@@ -2371,8 +2372,6 @@
return retval;
}
- assert(ss);
-
/* Update session state */
if (status < 300 || application != 0) {
assert(ss->ss_state != nua_callstate_calling);
@@ -3148,14 +3147,15 @@
{
nua_handle_t *nh = cr->cr_owner;
nua_dialog_usage_t *du = cr->cr_usage;
- nua_session_usage_t *ss = nua_dialog_usage_private(du);
+ nua_session_usage_t *ss;
nua_server_request_t *sr;
nua_client_request_t *cri;
int offer_sent = 0, retval;
if (du == NULL) /* Call terminated */
return nua_client_return(cr, SIP_481_NO_TRANSACTION, msg);
- assert(ss);
+
+ ss = NUA_DIALOG_USAGE_PRIVATE(du);
if (ss->ss_state >= nua_callstate_terminating)
return nua_client_return(cr, 900, "Session is terminating", msg);
More information about the Freeswitch-svn
mailing list