git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@57053
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
}
/* Do timeout check (shared between audio/dtmf) */
- if (started == 1) {
+ if (!quieted && started == 1) {
time(¤t);
if ((current-start) >= timeout) {
done = 1;
/* Do checks on speech structure to see if it's changed */
ast_mutex_lock(&speech->lock);
- if (ast_test_flag(speech, AST_SPEECH_QUIET) && chan->stream != NULL) {
- ast_stopstream(chan);
+ if (ast_test_flag(speech, AST_SPEECH_QUIET)) {
+ if (chan->stream)
+ ast_stopstream(chan);
ast_clear_flag(speech, AST_SPEECH_QUIET);
quieted = 1;
}