aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authordvossel <dvossel@f38db490-d61c-443f-a65b-d21fe96a405b>2010-01-08 19:44:54 +0000
committerdvossel <dvossel@f38db490-d61c-443f-a65b-d21fe96a405b>2010-01-08 19:44:54 +0000
commit927ab4902264b25aa68d69522c86f39a94322930 (patch)
tree32191a0e6344dca595f261ce8c0592161df4f4b5 /include
parentd7c5778dc0f65ea9b0e158fa726be39e7a5bafff (diff)
Merged revisions 238635 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk ........ r238635 | dvossel | 2010-01-08 13:39:30 -0600 (Fri, 08 Jan 2010) | 22 lines fixes AUDIOHOOK_INHERIT regression During the process of removing an audiohook from one channel and attaching it to another the audiohook's status is updated to DONE and then back to whatever it was previously. Typically updating the status after setting it to DONE is not a good idea because DONE can trigger unrecoverable audiohook destruction events... because of this a conditional check was added to audiohook_update_status to explicitly prevent the audiohook from ever changing after being set to DONE. It was this check that prevented audiohook inherit from work properly though. Now ast_audiohook_move_by_source is treated as a special exception, as the audiohook must be returned to its previous status after attaching it to the new channel. This is only a safe operation because the audiohook's lock is held the entire time, otherwise this could cause trouble. (closes issue #16522) Reported by: corruptor ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.0@238639 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'include')
-rw-r--r--include/asterisk/audiohook.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/asterisk/audiohook.h b/include/asterisk/audiohook.h
index 6f62ef66d..0a36bb934 100644
--- a/include/asterisk/audiohook.h
+++ b/include/asterisk/audiohook.h
@@ -205,6 +205,9 @@ struct ast_frame *ast_audiohook_write_list(struct ast_channel *chan, struct ast_
/*! \brief Update audiohook's status
* \param audiohook Audiohook structure
* \param audiohook status enum
+ *
+ * \note once status is updated to DONE, this function can not be used to set the
+ * status back to any other setting. Setting DONE effectively locks the status as such.
*/
void ast_audiohook_update_status(struct ast_audiohook *audiohook, enum ast_audiohook_status status);