mirror of
https://github.com/asterisk/asterisk.git
synced 2025-10-23 21:19:09 +00:00
Fix res_ari_asterisk load issue
The new res_ari_asterisk.so module presents several config options from asterisk main. Unfortunately, they aren't exported, so the module won't load on Linux. This patch renames the variables, adding the ast_ prefix so they will be exported. Review: https://reviewboard.asterisk.org/r/2737 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@396166 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -99,7 +99,7 @@ void ast_ari_get_asterisk_info(struct ast_variable *headers,
|
||||
" s: { s: s, s: s } }",
|
||||
|
||||
"name", ast_config_AST_SYSTEM_NAME,
|
||||
"default_language", defaultlanguage,
|
||||
"default_language", ast_defaultlanguage,
|
||||
|
||||
"setid",
|
||||
"user", ast_config_AST_RUN_USER,
|
||||
@@ -107,19 +107,19 @@ void ast_ari_get_asterisk_info(struct ast_variable *headers,
|
||||
|
||||
res |= ast_json_object_set(json, "config", config);
|
||||
|
||||
if (option_maxcalls) {
|
||||
if (ast_option_maxcalls) {
|
||||
res |= ast_json_object_set(config, "max_channels",
|
||||
ast_json_integer_create(option_maxcalls));
|
||||
ast_json_integer_create(ast_option_maxcalls));
|
||||
}
|
||||
|
||||
if (option_maxfiles) {
|
||||
if (ast_option_maxfiles) {
|
||||
res |= ast_json_object_set(config, "max_open_files",
|
||||
ast_json_integer_create(option_maxfiles));
|
||||
ast_json_integer_create(ast_option_maxfiles));
|
||||
}
|
||||
|
||||
if (option_maxload) {
|
||||
if (ast_option_maxload) {
|
||||
res |= ast_json_object_set(config, "max_load",
|
||||
ast_json_real_create(option_maxload));
|
||||
ast_json_real_create(ast_option_maxload));
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user