[svn-commits] mattf: trunk r263 - in /trunk: isup.c isup.h libss7.h

SVN commits to the Digium repositories svn-commits at lists.digium.com
Tue Apr 28 17:31:47 CDT 2009


Author: mattf
Date: Tue Apr 28 17:31:42 2009
New Revision: 263

URL: http://svn.digium.com/svn-view/libss7?view=rev&rev=263
Log:
Add libss7 support for COT on previous CIC (#13495)

Modified:
    trunk/isup.c
    trunk/isup.h
    trunk/libss7.h

Modified: trunk/isup.c
URL: http://svn.digium.com/svn-view/libss7/trunk/isup.c?view=diff&rev=263&r1=262&r2=263
==============================================================================
--- trunk/isup.c (original)
+++ trunk/isup.c Tue Apr 28 17:31:42 2009
@@ -379,6 +379,11 @@
 		c->cot_check_required = 1;
 	else
 		c->cot_check_required = 0;
+
+	if (cci == 0x2)
+		c->cot_performed_on_previous_cic = 1;
+	else
+		c->cot_performed_on_previous_cic = 0;
 
 	if (parm[0] & 0x10)
 		c->echocontrol_ind = 1;
@@ -3306,6 +3311,7 @@
 			e->sam.got_sent_msg = c->got_sent_msg;
 			e->sam.cot_check_passed = c->cot_check_passed;
 			e->sam.cot_check_required = c->cot_check_required;
+			e->sam.cot_performed_on_previous_cic = c->cot_performed_on_previous_cic;
 			isup_start_timer(ss7, c, ISUP_TIMER_T35);
 			return 0;
 		case ISUP_INF:
@@ -3541,7 +3547,7 @@
 			return 0;
 		case ISUP_COT:
 			/* Got we CCR or CCR in IAM ?*/
-			if (!(c->got_sent_msg & ISUP_GOT_CCR)) {
+			if (!(c->got_sent_msg & ISUP_GOT_CCR) & !c->cot_performed_on_previous_cic) {
 				ss7_message(ss7, "Got COT but we didn't got CCR previously on CIC %d PC %d ", c->cic, opc);
 				return isup_handle_unexpected(ss7, c, opc);
 			}
@@ -3556,6 +3562,7 @@
 			e->e = ISUP_EVENT_COT;
 			e->cot.cic = c->cic;
 			e->cot.passed = c->cot_check_passed;
+			e->cot.cot_performed_on_previous_cic = c->cot_performed_on_previous_cic;
 			if (!c->cot_check_passed)
 				c->got_sent_msg &= ~ISUP_GOT_IAM; /* we will get a new IAM but we are kepping the call */
 			e->cot.call = c;
@@ -3938,6 +3945,7 @@
 	e->iam.cic = c->cic;
 	e->iam.transcap = c->transcap;
 	e->iam.cot_check_required = c->cot_check_required;
+	e->iam.cot_performed_on_previous_cic = c->cot_performed_on_previous_cic;
 	c->cot_check_passed = 0;
 	strncpy(e->iam.called_party_num, c->called_party_num, sizeof(e->iam.called_party_num));
 	e->iam.called_nai = c->called_nai;

Modified: trunk/isup.h
URL: http://svn.digium.com/svn-view/libss7/trunk/isup.h?view=diff&rev=263&r1=262&r2=263
==============================================================================
--- trunk/isup.h (original)
+++ trunk/isup.h Tue Apr 28 17:31:42 2009
@@ -146,6 +146,7 @@
 #define ISUP_TIMER_T5 5
 #define ISUP_TIMER_T6 6
 #define ISUP_TIMER_T7 7
+#define ISUP_TIMER_T8 8
 #define ISUP_TIMER_T12 12
 #define ISUP_TIMER_T13 13
 #define ISUP_TIMER_T14 14
@@ -242,6 +243,7 @@
 	int causeloc;
 	int cot_check_passed;
 	int cot_check_required;
+	int cot_performed_on_previous_cic;
 	int cicgroupsupervisiontype;
 	unsigned char event_info;
 	unsigned short cic;

Modified: trunk/libss7.h
URL: http://svn.digium.com/svn-view/libss7/trunk/libss7.h?view=diff&rev=263&r1=262&r2=263
==============================================================================
--- trunk/libss7.h (original)
+++ trunk/libss7.h Tue Apr 28 17:31:42 2009
@@ -179,6 +179,7 @@
 	int cic;
 	int transcap;
 	int cot_check_required;
+	int cot_performed_on_previous_cic;
 	char called_party_num[50];
 	unsigned char called_nai;
 	char calling_party_num[50];
@@ -323,6 +324,7 @@
 	int e;
 	int cic;
 	int passed;
+	int cot_performed_on_previous_cic;
 	unsigned int opc;
 	unsigned long got_sent_msg;
 	struct isup_call *call;
@@ -369,6 +371,7 @@
 	unsigned char called_nai;
 	int cot_check_required;
 	int cot_check_passed;
+	int cot_performed_on_previous_cic;
 	unsigned long got_sent_msg;
 	struct isup_call *call;
 } ss7_event_sam;




More information about the svn-commits mailing list