]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
do parse defaultlanguage from asterisk.conf
authorTzafrir Cohen <tzafrir.cohen@xorcom.com>
Tue, 13 Sep 2011 21:33:20 +0000 (21:33 +0000)
committerTzafrir Cohen <tzafrir.cohen@xorcom.com>
Tue, 13 Sep 2011 21:33:20 +0000 (21:33 +0000)
Do parse the option "defaultlanguage" from the [options] section of
asterisk.conf, as in the sample config file. Otherwise the build-time
default language (normally "en") is always the default one.

Review: https://reviewboard.asterisk.org/r/1342/
Signed-off-by: Tzafrir Cohen (License #5035) <tzafrir.cohen@xorcom.com>
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@335716 65c4cc65-6c06-0410-ace0-fbb531ad65f3

main/asterisk.c

index 2fb4d021f561522b192cda1fd2e01145b52f65dd..b54ab03cad6a1e41717c01e3deca8ce8f6c04dae 100644 (file)
@@ -3032,6 +3032,8 @@ static void ast_readconfig(void)
                        }
                } else if (!strcasecmp(v->name, "languageprefix")) {
                        ast_language_is_prefix = ast_true(v->value);
+               } else if (!strcasecmp(v->name, "defaultlanguage")) {
+                       ast_copy_string(defaultlanguage, v->value, MAX_LANGUAGE);
                } else if (!strcasecmp(v->name, "lockmode")) {
                        if (!strcasecmp(v->value, "lockfile")) {
                                ast_set_lock_type(AST_LOCK_TYPE_LOCKFILE);