aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjpeeler <jpeeler@f38db490-d61c-443f-a65b-d21fe96a405b>2010-04-30 22:22:46 +0000
committerjpeeler <jpeeler@f38db490-d61c-443f-a65b-d21fe96a405b>2010-04-30 22:22:46 +0000
commit6d95a7f5b0feb0f06ea1180848d0c3dada1ad6ee (patch)
tree1f06bc43df4a715dea99670614d735b47e1dfb71
parent3722f0ac1c0777b4f85fc5899ff935ab82c564d5 (diff)
Ensure channel state is not incorrectly set in the case of a very early answer.
The needringing bit was being read in dahdi_read after answering thereby setting the state to ringing from up. This clears needringing upon answering so that is no longer possible. (closes issue #17067) Reported by: tzafrir Patches: needringing.diff uploaded by tzafrir (license 46) git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@260434 f38db490-d61c-443f-a65b-d21fe96a405b
-rw-r--r--channels/chan_dahdi.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/channels/chan_dahdi.c b/channels/chan_dahdi.c
index 7d5ec489b..5582ae5de 100644
--- a/channels/chan_dahdi.c
+++ b/channels/chan_dahdi.c
@@ -4445,7 +4445,7 @@ static struct ast_frame *dahdi_handle_event(struct ast_channel *ast)
p->subs[index].f.frametype = AST_FRAME_CONTROL;
p->subs[index].f.subclass = AST_CONTROL_ANSWER;
/* Make sure it stops ringing */
- dahdi_set_hook(p->subs[index].dfd, DAHDI_OFFHOOK);
+ p->subs[SUB_REAL].needringing = 0;
ast_log(LOG_DEBUG, "channel %d answered\n", p->channel);
if (p->cidspill) {
/* Cancel any running CallerID spill */