pjsip_configuration.c: Ignore repeated identify by methods.
authorRichard Mudgett <rmudgett@digium.com>
Mon, 29 Aug 2016 23:06:48 +0000 (18:06 -0500)
committerRichard Mudgett <rmudgett@digium.com>
Fri, 2 Sep 2016 18:21:32 +0000 (13:21 -0500)
Change-Id: Ied0c06043d1dfef8fdc9c9a808cf89b118119838

res/res_pjsip/pjsip_configuration.c

index 333be71..d8ae9e0 100644 (file)
@@ -603,6 +603,10 @@ static int ident_handler(const struct aco_option *opt, struct ast_variable *var,
                        endpoint->ident_method = 0;
                        return -1;
                }
+               if (endpoint->ident_method & method) {
+                       /* We are already indentifying by this method.  No need to do it again. */
+                       continue;
+               }
 
                endpoint->ident_method |= method;
                AST_VECTOR_APPEND(&endpoint->ident_method_order, method);