mirror of
https://github.com/asterisk/asterisk.git
synced 2025-09-02 19:16:15 +00:00
Refactor CEL channel events on top of Stasis-Core
This uses the channel state change events from Stasis-Core to determine when channel-related CEL events should be raised. Those refactored in this patch are: * AST_CEL_CHANNEL_START * AST_CEL_ANSWER * AST_CEL_APP_START * AST_CEL_APP_END * AST_CEL_HANGUP * AST_CEL_CHANNEL_END Retirement of Linked IDs is also refactored. CEL configuration has been refactored to use the config framework. Note: Some HANGUP events are not generated correctly because the bridge layer does not propagate hangupcause/hangupsource information yet. Review: https://reviewboard.asterisk.org/r/2544/ (closes issue ASTERISK-21563) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@391622 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -435,12 +435,23 @@ static int process_category(struct ast_config *cfg, struct aco_info *info, struc
|
||||
* We do not grab a reference to these objects, as the info already holds references to them. This
|
||||
* pointer is just a convenience. Do not actually store it somewhere. */
|
||||
void **field;
|
||||
regex_t *regex_skip;
|
||||
|
||||
/* Skip preloaded categories if we aren't preloading */
|
||||
if (!preload && is_preload(file, cat)) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
/* Skip the category if we've been told to ignore it */
|
||||
if (!ast_strlen_zero(file->skip_category)) {
|
||||
regex_skip = build_regex(file->skip_category);
|
||||
if (!regexec(regex_skip, cat, 0, NULL, 0)) {
|
||||
ast_free(regex_skip);
|
||||
return 0;
|
||||
}
|
||||
ast_free(regex_skip);
|
||||
}
|
||||
|
||||
/* Find aco_type by category, if not found it is an error */
|
||||
if (!(type = internal_aco_type_find(file, cfg, cat))) {
|
||||
ast_log(LOG_ERROR, "Could not find config type for category '%s' in '%s'\n", cat, file->filename);
|
||||
|
Reference in New Issue
Block a user