[asterisk-commits] mattf: trunk r47456 - /trunk/channels/chan_zap.c

asterisk-commits at lists.digium.com asterisk-commits at lists.digium.com
Fri Nov 10 12:35:42 MST 2006


Author: mattf
Date: Fri Nov 10 13:35:41 2006
New Revision: 47456

URL: http://svn.digium.com/view/asterisk?view=rev&rev=47456
Log:
Add fix for 7321.  Ability to hide calleridname from zapata.conf

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=47456&r1=47455&r2=47456
==============================================================================
--- trunk/channels/chan_zap.c (original)
+++ trunk/channels/chan_zap.c Fri Nov 10 13:35:41 2006
@@ -246,6 +246,8 @@
 static int callwaitingcallerid = 0;
 
 static int hidecallerid = 0;
+
+static int hidecalleridname = 0;
 
 static int restrictcid = 0;
 
@@ -613,6 +615,7 @@
 	unsigned int hanguponpolarityswitch:1;
 	unsigned int hardwaredtmf:1;
 	unsigned int hidecallerid;
+	unsigned int hidecalleridname;      /*!< Hide just the name not the number for legacy PBX use */
 	unsigned int ignoredtmf:1;
 	unsigned int immediate:1;			/*!< Answer before getting digits? */
 	unsigned int inalarm:1;
@@ -2239,6 +2242,10 @@
 			c++;
 		else
 			c = dest;
+		if (!p->hidecalleridname)
+			n = ast->cid.cid_name;
+		else
+			n = NULL;
 		if (!p->hidecallerid) {
 			l = ast->cid.cid_num;
 			n = ast->cid.cid_name;
@@ -8337,7 +8344,7 @@
 	}
 }
 
-static int ss7_reset_linkset(struct zt_ss7 *linkset)
+static void ss7_reset_linkset(struct zt_ss7 *linkset)
 {
 	int i, startcic = -1, endcic;
 
@@ -11820,6 +11827,8 @@
 				echotraining = 0;
 		} else if (!strcasecmp(v->name, "hidecallerid")) {
 			hidecallerid = ast_true(v->value);
+		} else if (!strcasecmp(v->name, "hidecalleridname")) {
+			hidecalleridname = ast_true(v->value);
  		} else if (!strcasecmp(v->name, "pulsedial")) {
  			pulse = ast_true(v->value);
 		} else if (!strcasecmp(v->name, "callreturn")) {



More information about the asterisk-commits mailing list