|
|
@ -3200,19 +3200,16 @@ static int handle_request(struct mgcp_subchannel *sub, struct mgcp_request *req,
|
|
|
|
(((ev[0] >= '0') && (ev[0] <= '9')) ||
|
|
|
|
(((ev[0] >= '0') && (ev[0] <= '9')) ||
|
|
|
|
((ev[0] >= 'A') && (ev[0] <= 'D')) ||
|
|
|
|
((ev[0] >= 'A') && (ev[0] <= 'D')) ||
|
|
|
|
(ev[0] == '*') || (ev[0] == '#'))) {
|
|
|
|
(ev[0] == '*') || (ev[0] == '#'))) {
|
|
|
|
if (sub && (sub->owner->_state >= AST_STATE_UP)) {
|
|
|
|
if (sub && sub->owner && (sub->owner->_state >= AST_STATE_UP)) {
|
|
|
|
f.frametype = AST_FRAME_DTMF;
|
|
|
|
f.frametype = AST_FRAME_DTMF;
|
|
|
|
f.subclass = ev[0];
|
|
|
|
f.subclass = ev[0];
|
|
|
|
f.src = "mgcp";
|
|
|
|
f.src = "mgcp";
|
|
|
|
if (sub->owner) {
|
|
|
|
/* XXX MUST queue this frame to all subs in threeway call if threeway call is active */
|
|
|
|
/* XXX MUST queue this frame to all subs in threeway call if threeway call is active */
|
|
|
|
mgcp_queue_frame(sub, &f);
|
|
|
|
mgcp_queue_frame(sub, &f);
|
|
|
|
ast_mutex_lock(&sub->next->lock);
|
|
|
|
ast_mutex_lock(&sub->next->lock);
|
|
|
|
if (sub->next->owner)
|
|
|
|
if (sub->next->owner) {
|
|
|
|
mgcp_queue_frame(sub->next, &f);
|
|
|
|
mgcp_queue_frame(sub->next, &f);
|
|
|
|
ast_mutex_unlock(&sub->next->lock);
|
|
|
|
}
|
|
|
|
|
|
|
|
ast_mutex_unlock(&sub->next->lock);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
if (strstr(p->curtone, "wt") && (ev[0] == 'A')) {
|
|
|
|
if (strstr(p->curtone, "wt") && (ev[0] == 'A')) {
|
|
|
|
memset(p->curtone, 0, sizeof(p->curtone));
|
|
|
|
memset(p->curtone, 0, sizeof(p->curtone));
|
|
|
|
}
|
|
|
|
}
|
|
|
|