aboutsummaryrefslogtreecommitdiffstats
path: root/channels
diff options
context:
space:
mode:
authormurf <murf@f38db490-d61c-443f-a65b-d21fe96a405b>2007-08-29 20:55:40 +0000
committermurf <murf@f38db490-d61c-443f-a65b-d21fe96a405b>2007-08-29 20:55:40 +0000
commit88e10708c5ba8158ee4fdf1aa08585739125b5da (patch)
treed08154c0eafb287f12d6b28ce99eea6938c21ce8 /channels
parent2149521341f36fb9f90d61796969f2665daca309 (diff)
This code was in team/murf/bug8684-trunk; it should fix bug 8684 in trunk. I didn't add it to 1.4 yet, because it's not entirely clear to me if this is a bug fix or an enhancement. A lot of files were affected by small changes like ast_variable_new getting an added arg, for the file name the var was defined in; ast_category_new gets added args of filename and lineno; ast_category and ast_variable structures now record file and lineno for each entry; a list of all #include and #execs in a config file (or any of its inclusions are now kept in the ast_config struct; at save time, each entry is put back into its proper file of origin, in order. #include and #exec directives are folded in properly. Headers indicating that the file was generated, are generated also for each included file. Some changes to main/manager.c to take care of file renaming, via the UpdateConfig command. Multiple inclusions of the same file are handled by exploding these into multiple include files, uniquely named. There's probably more, but I can't remember it right now.
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@81361 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'channels')
-rw-r--r--channels/chan_iax2.c4
-rw-r--r--channels/chan_sip.c4
-rw-r--r--channels/chan_skinny.c2
-rw-r--r--channels/iax2-parser.c4
4 files changed, 7 insertions, 7 deletions
diff --git a/channels/chan_iax2.c b/channels/chan_iax2.c
index 73bac9101..bc6f68661 100644
--- a/channels/chan_iax2.c
+++ b/channels/chan_iax2.c
@@ -5225,7 +5225,7 @@ static int check_access(int callno, struct sockaddr_in *sin, struct iax_ies *ies
/* We found our match (use the first) */
/* copy vars */
for (v = user->vars ; v ; v = v->next) {
- if((tmpvar = ast_variable_new(v->name, v->value))) {
+ if((tmpvar = ast_variable_new(v->name, v->value, v->file))) {
tmpvar->next = iaxs[callno]->vars;
iaxs[callno]->vars = tmpvar;
}
@@ -9741,7 +9741,7 @@ static struct iax2_user *build_user(const char *name, struct ast_variable *v, st
if (varname && (varval = strchr(varname,'='))) {
*varval = '\0';
varval++;
- if((tmpvar = ast_variable_new(varname, varval))) {
+ if((tmpvar = ast_variable_new(varname, varval, ""))) {
tmpvar->next = user->vars;
user->vars = tmpvar;
}
diff --git a/channels/chan_sip.c b/channels/chan_sip.c
index b28cb0ba7..3325c962b 100644
--- a/channels/chan_sip.c
+++ b/channels/chan_sip.c
@@ -10028,7 +10028,7 @@ static struct ast_variable *copy_vars(struct ast_variable *src)
struct ast_variable *res = NULL, *tmp, *v = NULL;
for (v = src ; v ; v = v->next) {
- if ((tmp = ast_variable_new(v->name, v->value))) {
+ if ((tmp = ast_variable_new(v->name, v->value, v->file))) {
tmp->next = res;
res = tmp;
}
@@ -17137,7 +17137,7 @@ static struct ast_variable *add_var(const char *buf, struct ast_variable *list)
if ((varval = strchr(varname,'='))) {
*varval++ = '\0';
- if ((tmpvar = ast_variable_new(varname, varval))) {
+ if ((tmpvar = ast_variable_new(varname, varval, ""))) {
tmpvar->next = list;
list = tmpvar;
}
diff --git a/channels/chan_skinny.c b/channels/chan_skinny.c
index f8e22d93e..2cc091700 100644
--- a/channels/chan_skinny.c
+++ b/channels/chan_skinny.c
@@ -1463,7 +1463,7 @@ static struct ast_variable *add_var(const char *buf, struct ast_variable *list)
if ((varval = strchr(varname,'='))) {
*varval++ = '\0';
- if ((tmpvar = ast_variable_new(varname, varval))) {
+ if ((tmpvar = ast_variable_new(varname, varval, ""))) {
tmpvar->next = list;
list = tmpvar;
}
diff --git a/channels/iax2-parser.c b/channels/iax2-parser.c
index 1c52cca59..7357fce72 100644
--- a/channels/iax2-parser.c
+++ b/channels/iax2-parser.c
@@ -917,7 +917,7 @@ int iax_parse_ies(struct iax_ies *ies, unsigned char *data, int datalen)
int len = strlen(var2->value) + strlen(tmp2) + 1;
char *tmp3 = alloca(len);
snprintf(tmp3, len, "%s%s", var2->value, tmp2);
- var = ast_variable_new(tmp, tmp3);
+ var = ast_variable_new(tmp, tmp3, var2->file);
var->next = var2->next;
if (prev)
prev->next = var;
@@ -928,7 +928,7 @@ int iax_parse_ies(struct iax_ies *ies, unsigned char *data, int datalen)
}
}
if (!var2) {
- var = ast_variable_new(tmp, tmp2);
+ var = ast_variable_new(tmp, tmp2, "");
var->next = ies->vars;
ies->vars = var;
}