Summary:ASTERISK-22116: Bridge API Enhancements: Add the ability to selectively remove bridge feature hooks
Reporter:Matt Jordan (mjordan)Labels:Asterisk12
Date Opened:2013-07-18 19:33:32Date Closed:2013-08-09 12:43:18
Versions:12 Frequency of
Description:Right now, we don't have the ability to choose which feature hook gets removed easily.

There should be an API call in the Bridging Framework that lets an external user of the framework request that a specific bridging hook be removed.

/* BUGBUG Need to be able to selectively remove DTMF, hangup, and interval hooks. */
/*! \brief Structure that is the essence of a feature hook. */
struct ast_bridge_hook {
/*! Linked list information */
AST_LIST_ENTRY(ast_bridge_hook) entry;
/*! Callback that is called when hook is tripped */
ast_bridge_hook_callback callback;
/*! Callback to destroy hook_pvt data right before destruction. */
ast_bridge_hook_pvt_destructor destructor;
/*! Unique data that was passed into us */
void *hook_pvt;
/*! Flags determining when hooks should be removed from a bridge channel */
struct ast_flags remove_flags;
/*! Extra hook parameters. */
union {
/*! Extra parameters for a DTMF feature hook. */
struct ast_bridge_hook_dtmf dtmf;
/*! Extra parameters for an interval timer hook. */
struct ast_bridge_hook_timer timer;
} parms;
Comments:By: Richard Mudgett (rmudgett) 2013-07-19 12:06:07.517-0500

The necessity for this BUGBUG comment is lessened by the ast_bridge_hook_remove_flags enum defined just above the BUGBUG comment.  The bridge_features_remove() (soon to become ast_bridge_features_remove() with the DTMF atxfer work) is available to remove marked classes of hooks.

By: Matt Jordan (mjordan) 2013-08-09 12:43:18.056-0500

This issue was fixed (or at least, is no longer relevant) due to flags being added that let you control how bridge hooks are removed.