[Asterisk-cvs] asterisk/apps app_talkdetect.c,1.5,1.6
markster at lists.digium.com
markster at lists.digium.com
Sun Oct 31 21:01:25 CST 2004
Update of /usr/cvsroot/asterisk/apps
In directory mongoose.digium.com:/tmp/cvs-serv17612/apps
Modified Files:
app_talkdetect.c
Log Message:
Add TALK_DETECTED variable (bug #2628)
Index: app_talkdetect.c
===================================================================
RCS file: /usr/cvsroot/asterisk/apps/app_talkdetect.c,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -d -r1.5 -r1.6
--- app_talkdetect.c 2 Oct 2004 00:58:31 -0000 1.5
+++ app_talkdetect.c 1 Nov 2004 02:04:05 -0000 1.6
@@ -145,7 +145,13 @@
if (ms < 0)
ms = 0;
if ((ms > min) && ((max < 0) || (ms < max))) {
+ char ms_str[10];
ast_log(LOG_DEBUG, "Found qualified token of %d ms\n", ms);
+
+ /* Save detected talk time (in milliseconds) */
+ sprintf(ms_str, "%d", ms );
+ pbx_builtin_setvar_helper(chan, "TALK_DETECTED", ms_str);
+
if (ast_exists_extension(chan, chan->context, "talk", 1, chan->cid.cid_num)) {
strncpy(chan->exten, "talk", sizeof(chan->exten) -1 );
chan->priority = 0;
More information about the svn-commits
mailing list