Fix the UpdateConfig manager action to properly treat "variables" and "objects"

differently (a=b versus a=>b).
(issue #9568, reported by pari, patch by me)


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@61690 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
Russell Bryant
2007-04-20 18:19:18 +00:00
parent 32be6621f6
commit 70eb19121e
4 changed files with 39 additions and 45 deletions

View File

@@ -798,7 +798,7 @@ static void vm_change_password(struct ast_vm_user *vmu, const char *newpassword)
ast_log(LOG_WARNING, "Failed to get category structure.\n");
break;
}
ast_variable_update(cat, vmu->mailbox, new, NULL);
ast_variable_update(cat, vmu->mailbox, new, NULL, 0);
}
}
/* save the results */
@@ -830,7 +830,7 @@ static void vm_change_password(struct ast_vm_user *vmu, const char *newpassword)
break;
}
if (!var)
ast_variable_update(cat, "vmsecret", new, NULL);
ast_variable_update(cat, "vmsecret", new, NULL, 0);
else
ast_variable_append(cat, var);
}
@@ -3842,7 +3842,7 @@ static int vm_forwardoptions(struct ast_channel *chan, struct ast_vm_user *vmu,
*duration += prepend_duration;
msg_cat = ast_category_get(msg_cfg, "message");
snprintf(duration_str, 11, "%ld", *duration);
if (!ast_variable_update(msg_cat, "duration", duration_str, NULL)) {
if (!ast_variable_update(msg_cat, "duration", duration_str, NULL, 0)) {
config_text_file_save(textfile, msg_cfg, "app_voicemail");
STORE(curdir, vmu->mailbox, context, curmsg, chan, vmu, vmfmts, *duration, vms);
}