mirror of
https://github.com/asterisk/asterisk.git
synced 2025-09-03 11:25:35 +00:00
bridging: Give bridges a name and a known creator
Bridges have two new optional properties, a creator and a name. Certain consumers of bridges will automatically provide bridges that they create with these properties. Examples include app_bridgewait, res_parking, app_confbridge, and app_agent_pool. In addition, a name may now be provided as an argument to the POST function for creating new bridges via ARI. (closes issue AFS-47) Review: https://reviewboard.asterisk.org/r/3070/ ........ Merged revisions 404042 from http://svn.asterisk.org/svn/asterisk/branches/12 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@404043 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -127,6 +127,9 @@ static void ast_ari_bridges_create_cb(
|
||||
if (strcmp(i->name, "type") == 0) {
|
||||
args.type = (i->value);
|
||||
} else
|
||||
if (strcmp(i->name, "name") == 0) {
|
||||
args.name = (i->value);
|
||||
} else
|
||||
{}
|
||||
}
|
||||
/* Look for a JSON request entity */
|
||||
@@ -149,6 +152,10 @@ static void ast_ari_bridges_create_cb(
|
||||
if (field) {
|
||||
args.type = ast_json_string_get(field);
|
||||
}
|
||||
field = ast_json_object_get(body, "name");
|
||||
if (field) {
|
||||
args.name = ast_json_string_get(field);
|
||||
}
|
||||
ast_ari_bridges_create(headers, &args, response);
|
||||
#if defined(AST_DEVMODE)
|
||||
code = response->response_code;
|
||||
|
Reference in New Issue
Block a user