From: Steve Murphy Date: Fri, 22 Sep 2006 21:34:04 +0000 (+0000) Subject: This commits a change to return MODULE_LOAD_FAILURE on error, and SUCCESS (instead... X-Git-Tag: 1.6.0-beta1~3^2~4658 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=bcdb270c57d0576c82fb35f257cf66fde97fe829;p=thirdparty%2Fasterisk.git This commits a change to return MODULE_LOAD_FAILURE on error, and SUCCESS (instead of 0) when all goes well for bug 8004 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@43507 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- diff --git a/pbx/pbx_ael.c b/pbx/pbx_ael.c index f460b630f6..1594c82b38 100644 --- a/pbx/pbx_ael.c +++ b/pbx/pbx_ael.c @@ -3825,10 +3825,12 @@ static int pbx_load_module(void) ast_log(LOG_NOTICE, "AEL load process: verified config file name '%s'.\n", rfilename); } else { ast_log(LOG_ERROR, "Sorry, but %d syntax errors and %d semantic errors were detected. It doesn't make sense to compile.\n", errs, sem_err); + destroy_pval(parse_tree); /* free up the memory */ + return AST_MODULE_LOAD_FAILURE; } destroy_pval(parse_tree); /* free up the memory */ - return 0; + return AST_MODULE_LOAD_SUCCESS; } /* CLI interface */