|
|
|
@ -1127,7 +1127,7 @@ static struct match_char *add_pattern_node(struct ast_context *con, struct match
|
|
|
|
|
|
|
|
|
|
static struct match_char *add_exten_to_pattern_tree(struct ast_context *con, struct ast_exten *e1, int findonly)
|
|
|
|
|
{
|
|
|
|
|
struct match_char *m1=0,*m2=0;
|
|
|
|
|
struct match_char *m1 = NULL, *m2 = NULL;
|
|
|
|
|
int specif;
|
|
|
|
|
int already;
|
|
|
|
|
int pattern = 0;
|
|
|
|
@ -1453,7 +1453,7 @@ static int _extension_match_core(const char *pattern, const char *data, enum ext
|
|
|
|
|
{
|
|
|
|
|
mode &= E_MATCH_MASK; /* only consider the relevant bits */
|
|
|
|
|
|
|
|
|
|
if ( (mode == E_MATCH) && (pattern[0] == '_') && (strcasecmp(pattern,data)==0) ) /* note: if this test is left out, then _x. will not match _x. !!! */
|
|
|
|
|
if ( (mode == E_MATCH) && (pattern[0] == '_') && (!strcasecmp(pattern,data)) ) /* note: if this test is left out, then _x. will not match _x. !!! */
|
|
|
|
|
return 1;
|
|
|
|
|
|
|
|
|
|
if (pattern[0] != '_') { /* not a pattern, try exact or partial match */
|
|
|
|
@ -1628,12 +1628,12 @@ struct ast_exten *pbx_find_extension(struct ast_channel *chan,
|
|
|
|
|
const char *label, const char *callerid, enum ext_match_t action)
|
|
|
|
|
{
|
|
|
|
|
int x, res;
|
|
|
|
|
struct ast_context *tmp=0;
|
|
|
|
|
struct ast_exten *e=0, *eroot=0;
|
|
|
|
|
struct ast_include *i = 0;
|
|
|
|
|
struct ast_sw *sw = 0;
|
|
|
|
|
struct ast_exten pattern = {0};
|
|
|
|
|
struct scoreboard score = {0};
|
|
|
|
|
struct ast_context *tmp = NULL;
|
|
|
|
|
struct ast_exten *e = NULL, *eroot = NULL;
|
|
|
|
|
struct ast_include *i = NULL;
|
|
|
|
|
struct ast_sw *sw = NULL;
|
|
|
|
|
struct ast_exten pattern = {NULL, };
|
|
|
|
|
struct scoreboard score = {0, };
|
|
|
|
|
|
|
|
|
|
pattern.label = label;
|
|
|
|
|
pattern.priority = priority;
|
|
|
|
@ -2034,7 +2034,7 @@ void pbx_retrieve_variable(struct ast_channel *c, const char *var, char **ret, c
|
|
|
|
|
if (places[i] == &globals)
|
|
|
|
|
ast_rwlock_rdlock(&globalslock);
|
|
|
|
|
AST_LIST_TRAVERSE(places[i], variables, entries) {
|
|
|
|
|
if (strcasecmp(ast_var_name(variables), var)==0) {
|
|
|
|
|
if (!strcasecmp(ast_var_name(variables), var)) {
|
|
|
|
|
s = ast_var_value(variables);
|
|
|
|
|
break;
|
|
|
|
|
}
|
|
|
|
|