Much simpler than previous one ;-)

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@53880 65c4cc65-6c06-0410-ace0-fbb531ad65f3
1.4
Paul Cadach 19 years ago
parent 3a68e31940
commit f02a11732b

@ -69,22 +69,15 @@ static int echo_exec(struct ast_channel *chan, void *data)
break; break;
f->delivery.tv_sec = 0; f->delivery.tv_sec = 0;
f->delivery.tv_usec = 0; f->delivery.tv_usec = 0;
switch (f->frametype) { if (ast_write(chan, f)) {
case AST_FRAME_DTMF:
if (f->subclass == '#') {
res = 0;
if (ast_write(chan, f))
res = -1;
ast_frfree(f); ast_frfree(f);
goto end; goto end;
} }
/* fall through */ if ((f->frametype == AST_FRAME_DTMF) && (f->subclass == '#')) {
default: res = 0;
if (ast_write(chan, f)) {
ast_frfree(f); ast_frfree(f);
goto end; goto end;
} }
}
ast_frfree(f); ast_frfree(f);
} }
end: end:

Loading…
Cancel
Save