diff options
author | file <file@f38db490-d61c-443f-a65b-d21fe96a405b> | 2009-02-06 16:01:01 +0000 |
---|---|---|
committer | file <file@f38db490-d61c-443f-a65b-d21fe96a405b> | 2009-02-06 16:01:01 +0000 |
commit | 65fcfaf2b4b295b75738cdd1247aa6519cf76a7c (patch) | |
tree | 38965037d24e96e92fba28de033eaaf1b13576bc /main/audiohook.c | |
parent | 385db018b450f44778a711f4b90bf7e0394d8c93 (diff) |
Merged revisions 173902 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk
........
r173902 | file | 2009-02-06 11:59:17 -0400 (Fri, 06 Feb 2009) | 4 lines
Always detach and destroy the whisper and barge audiohooks. Additionally also allow an audiohook to be detached if it has not been attached.
(closes issue #14414)
Reported by: bluecrow76
........
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.1@173904 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'main/audiohook.c')
-rw-r--r-- | main/audiohook.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/main/audiohook.c b/main/audiohook.c index 262d5d496..2b0beac01 100644 --- a/main/audiohook.c +++ b/main/audiohook.c @@ -354,7 +354,7 @@ int ast_audiohook_attach(struct ast_channel *chan, struct ast_audiohook *audioho */ int ast_audiohook_detach(struct ast_audiohook *audiohook) { - if (audiohook->status == AST_AUDIOHOOK_STATUS_DONE) + if (audiohook->status == AST_AUDIOHOOK_STATUS_NEW || audiohook->status == AST_AUDIOHOOK_STATUS_DONE) return 0; audiohook->status = AST_AUDIOHOOK_STATUS_SHUTDOWN; |