[asterisk-commits] mattf: branch mattf/asterisk-ss7 r38759 - /team/mattf/asterisk-ss7/channels/

asterisk-commits at lists.digium.com asterisk-commits at lists.digium.com
Wed Aug 2 15:31:28 MST 2006


Author: mattf
Date: Wed Aug  2 17:31:27 2006
New Revision: 38759

URL: http://svn.digium.com/view/asterisk?rev=38759&view=rev
Log:
Add support for the connect message

Modified:
    team/mattf/asterisk-ss7/channels/chan_zap.c

Modified: team/mattf/asterisk-ss7/channels/chan_zap.c
URL: http://svn.digium.com/view/asterisk/team/mattf/asterisk-ss7/channels/chan_zap.c?rev=38759&r1=38758&r2=38759&view=diff
==============================================================================
--- team/mattf/asterisk-ss7/channels/chan_zap.c (original)
+++ team/mattf/asterisk-ss7/channels/chan_zap.c Wed Aug  2 17:31:27 2006
@@ -8027,6 +8027,7 @@
 	int chanpos;
 	pthread_attr_t attr;
 	struct pollfd pollers[NUM_DCHANS];
+	int cic;
 	int nextms = 0;
 
 	pthread_attr_init(&attr);
@@ -8238,12 +8239,17 @@
 					ast_mutex_unlock(&p->lock);
 				}
 				break;
+			case ISUP_EVENT_CON:
 			case ISUP_EVENT_ANM:
-				ast_log(LOG_DEBUG, "Got ANM for cic %d\n", e->anm.cic);
-				chanpos = ss7_find_cic(linkset, e->anm.cic);
+				if (e->e == ISUP_EVENT_CON)
+					cic = e->con.cic;
+				else
+					cic = e->anm.cic;
+
+				chanpos = ss7_find_cic(linkset, cic);
 				if (chanpos < 0) {
-					ast_log(LOG_WARNING, "ANM on unconfigured CIC %d\n", e->anm.cic);
-					isup_rel(ss7, e->anm.call, -1);
+					ast_log(LOG_WARNING, "ANM/CON on unconfigured CIC %d\n", cic);
+					isup_rel(ss7, (e->e == ISUP_EVENT_ANM) ? e->anm.call : e->con.call, -1);
 					break;
 				} else {
 					p = linkset->pvts[chanpos];



More information about the asterisk-commits mailing list