[asterisk-commits] murf: trunk r84327 - in /trunk: ./ pbx/ res/ael/

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Mon Oct 1 18:03:51 CDT 2007


Author: murf
Date: Mon Oct  1 18:03:50 2007
New Revision: 84327

URL: http://svn.digium.com/view/asterisk?view=rev&rev=84327
Log:
Merged revisions 84239 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r84239 | murf | 2007-10-01 14:27:52 -0600 (Mon, 01 Oct 2007) | 1 line

closes issue #10777 -- by returning a null for the parse tree when there's really nothing there, and making sure we don't try to do checking on a null tree.
........

Modified:
    trunk/   (props changed)
    trunk/pbx/pbx_ael.c
    trunk/res/ael/ael.tab.c
    trunk/res/ael/ael.y
    trunk/res/ael/pval.c

Propchange: trunk/
------------------------------------------------------------------------------
Binary property 'branch-1.4-merged' - no diff available.

Modified: trunk/pbx/pbx_ael.c
URL: http://svn.digium.com/view/asterisk/trunk/pbx/pbx_ael.c?view=diff&rev=84327&r1=84326&r2=84327
==============================================================================
--- trunk/pbx/pbx_ael.c (original)
+++ trunk/pbx/pbx_ael.c Mon Oct  1 18:03:50 2007
@@ -905,7 +905,7 @@
 
 static int pbx_load_module(void)
 {
-	int errs, sem_err, sem_warn, sem_note;
+	int errs=0, sem_err=0, sem_warn=0, sem_note=0;
 	char *rfilename;
 	struct ast_context *local_contexts=NULL, *con;
 	struct pval *parse_tree;

Modified: trunk/res/ael/ael.tab.c
URL: http://svn.digium.com/view/asterisk/trunk/res/ael/ael.tab.c?view=diff&rev=84327&r1=84326&r2=84327
==============================================================================
--- trunk/res/ael/ael.tab.c (original)
+++ trunk/res/ael/ael.tab.c Mon Oct  1 18:03:50 2007
@@ -2137,8 +2137,8 @@
 		if (!(yyvsp[(5) - (6)].pval)) {
                         ast_log(LOG_WARNING, "==== File: %s, Line %d, Cols: %d-%d: Warning! The empty context %s will be IGNORED!\n", 
 				my_file, (yylsp[(4) - (6)]).first_line, (yylsp[(4) - (6)]).first_column, (yylsp[(4) - (6)]).last_column, (yyvsp[(3) - (6)].str) );
+			(yyval.pval) = 0;
 			free((yyvsp[(3) - (6)].str));
-
 		} else {
 			(yyval.pval) = npval2(PV_CONTEXT, &(yylsp[(1) - (6)]), &(yylsp[(6) - (6)]));
 			(yyval.pval)->u1.str = (yyvsp[(3) - (6)].str);

Modified: trunk/res/ael/ael.y
URL: http://svn.digium.com/view/asterisk/trunk/res/ael/ael.y?view=diff&rev=84327&r1=84326&r2=84327
==============================================================================
--- trunk/res/ael/ael.y (original)
+++ trunk/res/ael/ael.y Mon Oct  1 18:03:50 2007
@@ -205,8 +205,8 @@
 		if (!$5) {
                         ast_log(LOG_WARNING, "==== File: %s, Line %d, Cols: %d-%d: Warning! The empty context %s will be IGNORED!\n", 
 				my_file, @4.first_line, @4.first_column, @4.last_column, $3 );
+			$$ = 0;
 			free($3);
-
 		} else {
 			$$ = npval2(PV_CONTEXT, &@1, &@6);
 			$$->u1.str = $3;

Modified: trunk/res/ael/pval.c
URL: http://svn.digium.com/view/asterisk/trunk/res/ael/pval.c?view=diff&rev=84327&r1=84326&r2=84327
==============================================================================
--- trunk/res/ael/pval.c (original)
+++ trunk/res/ael/pval.c Mon Oct  1 18:03:50 2007
@@ -2871,6 +2871,8 @@
 #endif
 	struct argapp *apps=0;
 
+	if (!item)
+		return; /* don't check an empty tree */
 #ifdef AAL_ARGCHECK
 	rfilename = alloca(10 + strlen(ast_config_AST_VAR_DIR));
 	sprintf(rfilename, "%s/applist", ast_config_AST_VAR_DIR);




More information about the asterisk-commits mailing list