aboutsummaryrefslogtreecommitdiffstats
path: root/channel.c
diff options
context:
space:
mode:
authorkpfleming <kpfleming@f38db490-d61c-443f-a65b-d21fe96a405b>2006-01-29 05:15:24 +0000
committerkpfleming <kpfleming@f38db490-d61c-443f-a65b-d21fe96a405b>2006-01-29 05:15:24 +0000
commit9c36c7330fb7c12c8e829afac420fe883de5e3b1 (patch)
tree49f27042fcdb58a5e697ab2d1ec3d98fd8e84e0b /channel.c
parentd6dcf07573202bf10e5c153c613fb6c246a90f5a (diff)
add channel-driver callbacks for variable length DTMF
teach ast_write() to call those new callbacks git-svn-id: http://svn.digium.com/svn/asterisk/trunk@8851 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'channel.c')
-rw-r--r--channel.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/channel.c b/channel.c
index 3db38b6cc..c961f575c 100644
--- a/channel.c
+++ b/channel.c
@@ -2295,9 +2295,16 @@ int ast_write(struct ast_channel *chan, struct ast_frame *fr)
ast_log(LOG_WARNING, "Don't know how to handle control frames yet\n");
break;
case AST_FRAME_DTMF_BEGIN:
+ if (chan->tech->send_digit_begin)
+ res = chan->tech->send_digit_begin(chan, fr->subclass);
+ else
+ res = 0;
+ break;
case AST_FRAME_DTMF_END:
- /* nothing to do with these yet */
- res = 0;
+ if (chan->tech->send_digit_end)
+ res = chan->tech->send_digit_end(chan);
+ else
+ res = 0;
break;
case AST_FRAME_DTMF:
ast_clear_flag(chan, AST_FLAG_BLOCKING);