[asterisk-commits] dvossel: branch 1.6.0 r203447 - in /branches/1.6.0: ./ main/

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Thu Jun 25 16:47:51 CDT 2009


Author: dvossel
Date: Thu Jun 25 16:47:47 2009
New Revision: 203447

URL: http://svn.asterisk.org/svn-view/asterisk?view=rev&rev=203447
Log:
Merged revisions 203444 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/trunk

........
  r203444 | dvossel | 2009-06-25 16:45:32 -0500 (Thu, 25 Jun 2009) | 4 lines
  
  fixes a few redundant conditions
  
  (issue #15269)
........

Modified:
    branches/1.6.0/   (props changed)
    branches/1.6.0/main/ast_expr2.c
    branches/1.6.0/main/ast_expr2.fl

Propchange: branches/1.6.0/
------------------------------------------------------------------------------
Binary property 'trunk-merged' - no diff available.

Modified: branches/1.6.0/main/ast_expr2.c
URL: http://svn.asterisk.org/svn-view/asterisk/branches/1.6.0/main/ast_expr2.c?view=diff&rev=203447&r1=203446&r2=203447
==============================================================================
--- branches/1.6.0/main/ast_expr2.c (original)
+++ branches/1.6.0/main/ast_expr2.c Thu Jun 25 16:47:47 2009
@@ -2397,7 +2397,6 @@
 free_value (struct val *vp)
 {	
 	if (vp==NULL) {
-		free(vp);
 		return;
 	}
 	if (vp->type == AST_EXPR_string || vp->type == AST_EXPR_numeric_string)

Modified: branches/1.6.0/main/ast_expr2.fl
URL: http://svn.asterisk.org/svn-view/asterisk/branches/1.6.0/main/ast_expr2.fl?view=diff&rev=203447&r1=203446&r2=203447
==============================================================================
--- branches/1.6.0/main/ast_expr2.fl (original)
+++ branches/1.6.0/main/ast_expr2.fl Thu Jun 25 16:47:47 2009
@@ -242,10 +242,10 @@
 
 void ast_yyfree(void *ptr, yyscan_t yyscanner)
 {
-      if (ptr) /* the normal generated yyfree func just frees its first arg;
-                    this get complaints on some systems, as sometimes this
-                    arg is a nil ptr! It's usually not fatal, but is irritating! */
-              free( (char *) ptr );
+    /* the normal generated yyfree func just frees its first arg;
+     this get complaints on some systems, as sometimes this
+     arg is a nil ptr! It's usually not fatal, but is irritating! */
+	free( (char *) ptr );
 }
 
 int ast_expr(char *expr, char *buf, int length, struct ast_channel *chan)
@@ -286,8 +286,7 @@
 			else
 				buf[0] = 0;
 			return_value = strlen(buf);
-			if (io.val->u.s)
-				free(io.val->u.s);
+			free(io.val->u.s);
 		}
 		free(io.val);
 	}




More information about the asterisk-commits mailing list