Skip to content

Commit e48ee94

Browse files
committed
Put speech channel into the ERROR state if the START-INPUT-TIMERS request fails.
1 parent 1bdb1a0 commit e48ee94

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

mod_unimrcp.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3666,6 +3666,8 @@ static apt_bool_t recog_on_message_receive(mrcp_application_t *application, mrcp
36663666
} else {
36673667
switch_log_printf(SWITCH_CHANNEL_UUID_LOG(schannel->session_uuid), SWITCH_LOG_DEBUG, "(%s) timers failed to start, status code = %d\n", schannel->name,
36683668
message->start_line.status_code);
3669+
/* Set ERROR state here to prevent call hang if server disconnects and can't respond to START-INPUT-TIMERS request. */
3670+
speech_channel_set_state(schannel, SPEECH_CHANNEL_ERROR);
36693671
}
36703672
}
36713673
} else if (message->start_line.method_id == RECOGNIZER_DEFINE_GRAMMAR) {

0 commit comments

Comments
 (0)