aboutsummaryrefslogtreecommitdiffstats
path: root/pbx
diff options
context:
space:
mode:
authorroot <root@f38db490-d61c-443f-a65b-d21fe96a405b>2006-02-11 19:03:03 +0000
committerroot <root@f38db490-d61c-443f-a65b-d21fe96a405b>2006-02-11 19:03:03 +0000
commitab0d6f99d8f35462645d7e4b3521d9061535663e (patch)
treea92efd77b8211b3d73698bdaba9a5f9cfb5c7428 /pbx
parent53df4a7ba9cd7fd91ca42f02d90661ec5e5e0d29 (diff)
automerge commit
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.2-netsec@9606 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'pbx')
-rw-r--r--pbx/pbx_spool.c13
1 files changed, 6 insertions, 7 deletions
diff --git a/pbx/pbx_spool.c b/pbx/pbx_spool.c
index a7dbed32c..a91a7e255 100644
--- a/pbx/pbx_spool.c
+++ b/pbx/pbx_spool.c
@@ -86,6 +86,9 @@ struct outgoing {
char cid_num[256];
char cid_name[256];
+ /* account code */
+ char account[AST_MAX_ACCOUNT_CODE];
+
/* Variables and Functions */
struct ast_variable *vars;
@@ -212,11 +215,7 @@ static int apply_outgoing(struct outgoing *o, char *fn, FILE *f)
ast_log(LOG_WARNING, "Malformed Set: argument! Should be Set: Variable=value\n");
}
} else if (!strcasecmp(buf, "account")) {
- var = ast_variable_new("CDR(accountcode|r)", c);
- if (var) {
- var->next = o->vars;
- o->vars = var;
- }
+ ast_copy_string(o->account, c, sizeof(o->account));
} else {
ast_log(LOG_WARNING, "Unknown keyword '%s' at line %d of %s\n", buf, lineno, fn);
}
@@ -260,11 +259,11 @@ static void *attempt_thread(void *data)
if (!ast_strlen_zero(o->app)) {
if (option_verbose > 2)
ast_verbose(VERBOSE_PREFIX_3 "Attempting call on %s/%s for application %s(%s) (Retry %d)\n", o->tech, o->dest, o->app, o->data, o->retries);
- res = ast_pbx_outgoing_app(o->tech, AST_FORMAT_SLINEAR, o->dest, o->waittime * 1000, o->app, o->data, &reason, 2 /* wait to finish */, o->cid_num, o->cid_name, o->vars, NULL);
+ res = ast_pbx_outgoing_app(o->tech, AST_FORMAT_SLINEAR, o->dest, o->waittime * 1000, o->app, o->data, &reason, 2 /* wait to finish */, o->cid_num, o->cid_name, o->vars, o->account, NULL);
} else {
if (option_verbose > 2)
ast_verbose(VERBOSE_PREFIX_3 "Attempting call on %s/%s for %s@%s:%d (Retry %d)\n", o->tech, o->dest, o->exten, o->context,o->priority, o->retries);
- res = ast_pbx_outgoing_exten(o->tech, AST_FORMAT_SLINEAR, o->dest, o->waittime * 1000, o->context, o->exten, o->priority, &reason, 2 /* wait to finish */, o->cid_num, o->cid_name, o->vars, NULL);
+ res = ast_pbx_outgoing_exten(o->tech, AST_FORMAT_SLINEAR, o->dest, o->waittime * 1000, o->context, o->exten, o->priority, &reason, 2 /* wait to finish */, o->cid_num, o->cid_name, o->vars, o->account, NULL);
}
if (res) {
ast_log(LOG_NOTICE, "Call failed to go through, reason %d\n", reason);