Skip to content

Commit b2fdccc

Browse files
InterLinked1Friendly Automation
authored andcommitted
res_tonedetect: Fix typos referring to wrong variables.
Fixes two typos that cause fax detection to not work. One refers to the wrong frame variable, and the other refers to the subclass.integer instead of the frametype as it should. ASTERISK-30192 #close Change-Id: I7b35fdb7bcf25a29a212eee37c20812c64ab3ef1
1 parent 1b6227a commit b2fdccc

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

‎res/res_tonedetect.c‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -940,8 +940,8 @@ static int scan_exec(struct ast_channel *chan, const char *data)
940940
} else if (fax) {
941941
char result;
942942
frame2 = ast_dsp_process(chan, dsp2, frame2);
943-
result = frame->subclass.integer;
944-
if (result == AST_FRAME_DTMF) {
943+
result = frame2->subclass.integer;
944+
if (frame2->frametype == AST_FRAME_DTMF) {
945945
if (result == 'e') {
946946
pbx_builtin_setvar_helper(chan, "TONESCANSTATUS", "FAX");
947947
match = 1;

0 commit comments

Comments
 (0)