[svn-commits] mattf: trunk r59204 - /trunk/channels/chan_zap.c

svn-commits at lists.digium.com svn-commits at lists.digium.com
Mon Mar 26 09:46:15 MST 2007


Author: mattf
Date: Mon Mar 26 11:46:07 2007
New Revision: 59204

URL: http://svn.digium.com/view/asterisk?view=rev&rev=59204
Log:
Small API related SS7 updates.

Modified:
    trunk/channels/chan_zap.c

Modified: trunk/channels/chan_zap.c
URL: http://svn.digium.com/view/asterisk/trunk/channels/chan_zap.c?view=diff&rev=59204&r1=59203&r2=59204
==============================================================================
--- trunk/channels/chan_zap.c (original)
+++ trunk/channels/chan_zap.c Mon Mar 26 11:46:07 2007
@@ -2767,7 +2767,14 @@
 			if (p->ss7call) {
 				if (!ss7_grab(p, p->ss7)) {
 					if (!p->alreadyhungup) {
-						isup_rel(p->ss7->ss7, p->ss7call, ast->hangupcause ? ast->hangupcause : -1);
+						const char *cause = pbx_builtin_getvar_helper(ast,"SS7_CAUSE");
+						int icause = ast->hangupcause ? ast->hangupcause : -1;
+
+						if (cause) {
+							if (atoi(cause))
+								icause = atoi(cause);
+						}
+						isup_rel(p->ss7->ss7, p->ss7call, icause);
 						ss7_rel(p->ss7);
 						p->alreadyhungup = 1;
 					} else
@@ -8741,11 +8748,11 @@
 				break;
 			case ISUP_EVENT_CGB:
 				ss7_block_cics(linkset, e->cgb.startcic, e->cgb.endcic, e->cgb.status, 1);
-				isup_cgba(linkset->ss7, e->cgb.startcic, e->cgb.endcic, e->cgb.status);
+				isup_cgba(linkset->ss7, e->cgb.startcic, e->cgb.endcic, e->cgb.status, e->cgb.type);
 				break;
 			case ISUP_EVENT_CGU:
 				ss7_block_cics(linkset, e->cgu.startcic, e->cgu.endcic, e->cgb.status, 0);
-				isup_cgua(linkset->ss7, e->cgu.startcic, e->cgu.endcic, e->cgb.status);
+				isup_cgua(linkset->ss7, e->cgu.startcic, e->cgu.endcic, e->cgb.status, e->cgu.type);
 				break;
 			case ISUP_EVENT_BLO:
 				chanpos = ss7_find_cic(linkset, e->blo.cic);



More information about the svn-commits mailing list