[Asterisk-cvs] asterisk/channels chan_zap.c,1.171.2.10,1.171.2.11
citats at lists.digium.com
citats at lists.digium.com
Wed Mar 10 03:40:48 CST 2004
Update of /usr/cvsroot/asterisk/channels
In directory mongoose.digium.com:/tmp/cvs-serv16372/channels
Modified Files:
Tag: v1-0_stable
chan_zap.c
Log Message:
Make distinctiveringdetection configurable per channel (bug 1168)
Index: chan_zap.c
===================================================================
RCS file: /usr/cvsroot/asterisk/channels/chan_zap.c,v
retrieving revision 1.171.2.10
retrieving revision 1.171.2.11
diff -u -d -r1.171.2.10 -r1.171.2.11
--- chan_zap.c 8 Mar 2004 04:26:56 -0000 1.171.2.10
+++ chan_zap.c 10 Mar 2004 08:33:29 -0000 1.171.2.11
@@ -388,6 +388,7 @@
struct zt_pvt *prev; /* Prev channel in list */
struct zt_distRings drings;
+ int usedistinctiveringdetection;
char context[AST_MAX_EXTENSION];
char defcontext[AST_MAX_EXTENSION];
@@ -4656,7 +4657,7 @@
break;
}
}
- if (usedistinctiveringdetection == 1) {
+ if (p->usedistinctiveringdetection == 1) {
if(option_verbose > 2)
/* this only shows up if you have n of the dring patterns filled in */
ast_verbose( VERBOSE_PREFIX_3 "Detected ring pattern: %d,%d,%d\n",curRingData[0],curRingData[1],curRingData[2]);
@@ -5511,6 +5512,7 @@
/* Flag to destroy the channel must be cleared on new mkif. Part of changes for reload to work */
tmp->destroy = 0;
tmp->drings = drings;
+ tmp->usedistinctiveringdetection = usedistinctiveringdetection;
tmp->callwaitingcallerid = callwaitingcallerid;
tmp->threewaycalling = threewaycalling;
tmp->adsi = adsi;
@@ -7357,7 +7359,7 @@
chan = strsep(&c, ",");
}
} else if (!strcasecmp(v->name, "usedistinctiveringdetection")) {
- if (!strcasecmp(v->value, "yes")) usedistinctiveringdetection = 1;
+ usedistinctiveringdetection = ast_true(v->value);
} else if (!strcasecmp(v->name, "dring1context")) {
strncpy(drings.ringContext[0].contextData,v->value,sizeof(drings.ringContext[0].contextData)-1);
} else if (!strcasecmp(v->name, "dring2context")) {
@@ -7840,7 +7842,7 @@
chan = strsep(&stringp, ",");
}
} else if (!strcasecmp(v->name, "usedistinctiveringdetection")) {
- if (!strcasecmp(v->value, "yes")) usedistinctiveringdetection = 1;
+ usedistinctiveringdetection = ast_true(v->value);
} else if (!strcasecmp(v->name, "dring1context")) {
strncpy(drings.ringContext[0].contextData,v->value,sizeof(drings.ringContext[0].contextData)-1);
} else if (!strcasecmp(v->name, "dring2context")) {
More information about the svn-commits
mailing list