mirror of
https://github.com/asterisk/asterisk.git
synced 2025-09-03 11:25:35 +00:00
ari/bridge: Add mute, dtmf suppression controls
Add bridge_features structure to bridge creation. Specifically, this implements mute and DTMF suppression, but others should be able to be easily added to the same structure. ASTERISK-27322 #close Reported by: Darren Sessions Sponsored by: AVOXI Change-Id: Id4002adfb65c9a8027ee9e1a5f477e0f01cf9d61
This commit is contained in:
@@ -430,6 +430,14 @@ int ast_ari_bridges_add_channel_parse_body(
|
||||
if (field) {
|
||||
args->role = ast_json_string_get(field);
|
||||
}
|
||||
field = ast_json_object_get(body, "absorbDTMF");
|
||||
if (field) {
|
||||
args->absorb_dtmf = ast_json_is_true(field);
|
||||
}
|
||||
field = ast_json_object_get(body, "mute");
|
||||
if (field) {
|
||||
args->mute = ast_json_is_true(field);
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -499,6 +507,12 @@ static void ast_ari_bridges_add_channel_cb(
|
||||
if (strcmp(i->name, "role") == 0) {
|
||||
args.role = (i->value);
|
||||
} else
|
||||
if (strcmp(i->name, "absorbDTMF") == 0) {
|
||||
args.absorb_dtmf = ast_true(i->value);
|
||||
} else
|
||||
if (strcmp(i->name, "mute") == 0) {
|
||||
args.mute = ast_true(i->value);
|
||||
} else
|
||||
{}
|
||||
}
|
||||
for (i = path_vars; i; i = i->next) {
|
||||
|
Reference in New Issue
Block a user