diff options
author | markster <markster@f38db490-d61c-443f-a65b-d21fe96a405b> | 2005-01-04 04:01:40 +0000 |
---|---|---|
committer | markster <markster@f38db490-d61c-443f-a65b-d21fe96a405b> | 2005-01-04 04:01:40 +0000 |
commit | e6f35a87bcdec06f2380b0804fd4c472977aed9c (patch) | |
tree | 29d4df585c7a16fb387fa5eb4daf553cdf195852 /apps/app_dial.c | |
parent | d481e222f25146b8cbd76c99bdf13c4b9a041d35 (diff) |
Make features configurable and easier to implement
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@4650 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'apps/app_dial.c')
-rwxr-xr-x | apps/app_dial.c | 18 |
1 files changed, 12 insertions, 6 deletions
diff --git a/apps/app_dial.c b/apps/app_dial.c index d1d76bcff..0226995d2 100755 --- a/apps/app_dial.c +++ b/apps/app_dial.c @@ -1135,12 +1135,18 @@ static int dial_exec(struct ast_channel *chan, void *data) if (!res) { memset(&config,0,sizeof(struct ast_bridge_config)); - config.play_to_caller=play_to_caller; - config.play_to_callee=play_to_callee; - config.allowredirect_in = allowredir_in; - config.allowredirect_out = allowredir_out; - config.allowdisconnect_in = allowdisconnect_in; - config.allowdisconnect_out = allowdisconnect_out; + if (play_to_caller) + config.features_caller |= AST_FEATURE_PLAY_WARNING; + if (play_to_callee) + config.features_callee |= AST_FEATURE_PLAY_WARNING; + if (allowredir_in) + config.features_callee |= AST_FEATURE_REDIRECT; + if (allowredir_out) + config.features_caller |= AST_FEATURE_REDIRECT; + if (allowdisconnect_in) + config.features_callee |= AST_FEATURE_DISCONNECT; + if (allowdisconnect_out) + config.features_caller |= AST_FEATURE_DISCONNECT; config.timelimit = timelimit; config.play_warning = play_warning; config.warning_freq = warning_freq; |