mirror of
https://github.com/asterisk/asterisk.git
synced 2025-09-04 11:58:52 +00:00
res_ari: Fix inverted test giving wrong error message.
The patch for ASTERISK_24560 inverted a test checking if the bridge name is being updated to a different name. * Fix the test to return "Changing bridge name is not implemented" when someone attempts to change the bridge name. ASTERISK-27445 Change-Id: I4b70bf08b0e02e016108b077ff75b345dec12fc9
This commit is contained in:
@@ -968,13 +968,12 @@ void ast_ari_bridges_create_with_id(struct ast_variable *headers,
|
||||
|
||||
if (bridge) {
|
||||
/* update */
|
||||
if (!ast_strlen_zero(args->name)) {
|
||||
if (!strcmp(args->name, bridge->name)) {
|
||||
ast_ari_response_error(
|
||||
response, 500, "Internal Error",
|
||||
"Changing bridge name is not implemented");
|
||||
return;
|
||||
}
|
||||
if (!ast_strlen_zero(args->name)
|
||||
&& strcmp(args->name, bridge->name)) {
|
||||
ast_ari_response_error(
|
||||
response, 500, "Internal Error",
|
||||
"Changing bridge name is not implemented");
|
||||
return;
|
||||
}
|
||||
if (!ast_strlen_zero(args->type)) {
|
||||
ast_ari_response_error(
|
||||
|
Reference in New Issue
Block a user