Fix speech structure leak in the AGI speech recognition integration.
The AGI dialplan applications did not destroy the speech structure automatically if it was not destroyed by the running AGI script. They will now do this. (issue LUMENVOX-15) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@184673 f38db490-d61c-443f-a65b-d21fe96a405b
This commit is contained in:
parent
6f9402c7e6
commit
aa844c8202
|
@ -737,6 +737,10 @@ static enum agi_result launch_asyncagi(struct ast_channel *chan, char *argv[], i
|
|||
ast_frfree(f);
|
||||
}
|
||||
}
|
||||
|
||||
if (async_agi.speech) {
|
||||
ast_speech_destroy(async_agi.speech);
|
||||
}
|
||||
quit:
|
||||
/* notify manager users this channel cannot be
|
||||
controlled anymore by Async AGI */
|
||||
|
@ -2929,6 +2933,9 @@ static enum agi_result run_agi(struct ast_channel *chan, char *request, AGI *agi
|
|||
}
|
||||
}
|
||||
}
|
||||
if (agi->speech) {
|
||||
ast_speech_destroy(agi->speech);
|
||||
}
|
||||
/* Notify process */
|
||||
if (send_sighup) {
|
||||
if (pid > -1) {
|
||||
|
|
Reference in New Issue