From 5537def54d23f6efac0840056f36228a2cfabc5d Mon Sep 17 00:00:00 2001 From: Joshua Colp Date: Wed, 27 Nov 2013 15:31:05 +0000 Subject: [PATCH] res_pjsip: Update handling of some options to work with new option names. Some options (such as call_group and pickup_group) share the same configuration handler and decide what logic to use based on the name of the option. These handlers were not updated to check for the new option names and were treating the options as invalid. This change simply updates the handlers with the proper names of the options. (closes issue ASTERISK-22922) Reported by: Anthony Messina git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/12@403173 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- res/res_pjsip/pjsip_configuration.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/res/res_pjsip/pjsip_configuration.c b/res/res_pjsip/pjsip_configuration.c index 24c53e8a99..364ed7e19b 100644 --- a/res/res_pjsip/pjsip_configuration.c +++ b/res/res_pjsip/pjsip_configuration.c @@ -666,11 +666,11 @@ static int group_handler(const struct aco_option *opt, { struct ast_sip_endpoint *endpoint = obj; - if (!strncmp(var->name, "callgroup", 9)) { + if (!strncmp(var->name, "call_group", 10)) { if (!(endpoint->pickup.callgroup = ast_get_group(var->value))) { return -1; } - } else if (!strncmp(var->name, "pickupgroup", 11)) { + } else if (!strncmp(var->name, "pickup_group", 12)) { if (!(endpoint->pickup.pickupgroup = ast_get_group(var->value))) { return -1; } @@ -710,12 +710,12 @@ static int named_groups_handler(const struct aco_option *opt, { struct ast_sip_endpoint *endpoint = obj; - if (!strncmp(var->name, "namedcallgroup", 14)) { + if (!strncmp(var->name, "named_call_group", 16)) { if (!(endpoint->pickup.named_callgroups = ast_get_namedgroups(var->value))) { return -1; } - } else if (!strncmp(var->name, "namedpickupgroup", 16)) { + } else if (!strncmp(var->name, "named_pickup_group", 18)) { if (!(endpoint->pickup.named_pickupgroups = ast_get_namedgroups(var->value))) { return -1;