summaryrefslogtreecommitdiff
path: root/apps/app_directory.c
diff options
context:
space:
mode:
authorTerry Wilson <twilson@digium.com>2012-01-24 20:12:09 +0000
committerTerry Wilson <twilson@digium.com>2012-01-24 20:12:09 +0000
commit99cae5b7508f30a308afbbacf92ad306a30f68df (patch)
treebdca00ce837e60a5f9a16fed06d02f6e77235035 /apps/app_directory.c
parent2144ba5df2813609024964c4c2d9060b30d5cd43 (diff)
Opaquify channel stringfields
Continue channel opaque-ification by wrapping all of the stringfields. Eventually, we will restrict what can actually set these variables, but the purpose for now is to hide the implementation and keep people from adding code that directly accesses the channel structure. Semantic changes will follow afterward. Review: https://reviewboard.asterisk.org/r/1661/ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@352348 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'apps/app_directory.c')
-rw-r--r--apps/app_directory.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/apps/app_directory.c b/apps/app_directory.c
index dccae948b..a4ec93e4c 100644
--- a/apps/app_directory.c
+++ b/apps/app_directory.c
@@ -273,13 +273,13 @@ static int play_mailbox_owner(struct ast_channel *chan, const char *context,
/* If Option 'e' was specified, also read the extension number with the name */
if (ast_test_flag(flags, OPT_SAYEXTENSION)) {
ast_stream_and_wait(chan, "vm-extension", AST_DIGIT_ANY);
- res = ast_say_character_str(chan, ext, AST_DIGIT_ANY, chan->language);
+ res = ast_say_character_str(chan, ext, AST_DIGIT_ANY, ast_channel_language(chan));
}
} else {
- res = ast_say_character_str(chan, S_OR(name, ext), AST_DIGIT_ANY, chan->language);
+ res = ast_say_character_str(chan, S_OR(name, ext), AST_DIGIT_ANY, ast_channel_language(chan));
if (!ast_strlen_zero(name) && ast_test_flag(flags, OPT_SAYEXTENSION)) {
ast_stream_and_wait(chan, "vm-extension", AST_DIGIT_ANY);
- res = ast_say_character_str(chan, ext, AST_DIGIT_ANY, chan->language);
+ res = ast_say_character_str(chan, ext, AST_DIGIT_ANY, ast_channel_language(chan));
}
}
@@ -383,15 +383,15 @@ static int select_item_menu(struct ast_channel *chan, struct directory_item **it
snprintf(buf, sizeof(buf), "digits/%d", i + 1);
/* Press <num> for <name>, [ extension <ext> ] */
- res = ast_streamfile(chan, "dir-multi1", chan->language);
+ res = ast_streamfile(chan, "dir-multi1", ast_channel_language(chan));
if (!res)
res = ast_waitstream(chan, AST_DIGIT_ANY);
if (!res)
- res = ast_streamfile(chan, buf, chan->language);
+ res = ast_streamfile(chan, buf, ast_channel_language(chan));
if (!res)
res = ast_waitstream(chan, AST_DIGIT_ANY);
if (!res)
- res = ast_streamfile(chan, "dir-multi2", chan->language);
+ res = ast_streamfile(chan, "dir-multi2", ast_channel_language(chan));
if (!res)
res = ast_waitstream(chan, AST_DIGIT_ANY);
if (!res)
@@ -404,7 +404,7 @@ static int select_item_menu(struct ast_channel *chan, struct directory_item **it
/* Press "9" for more names. */
if (!res && count > limit) {
- res = ast_streamfile(chan, "dir-multi9", chan->language);
+ res = ast_streamfile(chan, "dir-multi9", ast_channel_language(chan));
if (!res)
res = ast_waitstream(chan, AST_DIGIT_ANY);
}
@@ -710,7 +710,7 @@ static int do_directory(struct ast_channel *chan, struct ast_config *vmcfg, stru
}
if (count < 1) {
- res = ast_streamfile(chan, "dir-nomatch", chan->language);
+ res = ast_streamfile(chan, "dir-nomatch", ast_channel_language(chan));
goto exit;
}
@@ -742,7 +742,7 @@ static int do_directory(struct ast_channel *chan, struct ast_config *vmcfg, stru
}
if (!res) {
- res = ast_streamfile(chan, "dir-nomore", chan->language);
+ res = ast_streamfile(chan, "dir-nomore", ast_channel_language(chan));
}
exit: