dect
/
asterisk
Archived
13
0
Fork 0

As per bug 8004, we now return AST_MODULE_LOAD_DECLINE when we can't read extensions.ael

git-svn-id: http://svn.digium.com/svn/asterisk/trunk@43506 f38db490-d61c-443f-a65b-d21fe96a405b
This commit is contained in:
murf 2006-09-22 21:17:07 +00:00
parent 1e0cd5ceac
commit d55e6f507d
1 changed files with 6 additions and 0 deletions

View File

@ -28,6 +28,7 @@ ASTERISK_FILE_VERSION(__FILE__, "$Revision$")
#include <sys/types.h>
#include <stdlib.h>
#include <unistd.h>
#include <stdio.h>
#include <string.h>
#include <ctype.h>
@ -3803,6 +3804,11 @@ static int pbx_load_module(void)
sprintf(rfilename, "%s/%s", ast_config_AST_CONFIG_DIR, config);
}
ast_log(LOG_NOTICE, "AEL load process: calculated config file name '%s'.\n", rfilename);
if (access(rfilename,R_OK) != 0) {
ast_log(LOG_NOTICE, "File %s not found; AEL declining load\n", rfilename);
return AST_MODULE_LOAD_DECLINE;
}
parse_tree = ael2_parse(rfilename, &errs);
ast_log(LOG_NOTICE, "AEL load process: parsed config file name '%s'.\n", rfilename);