[asterisk-commits] tilghman: branch 1.8 r299583 - /branches/1.8/addons/res_config_mysql.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Fri Dec 24 17:58:33 UTC 2010


Author: tilghman
Date: Fri Dec 24 11:58:30 2010
New Revision: 299583

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=299583
Log:
Reset 'first' variable after usage.

(closes issue #18525)
 Reported by: makoto
 Patches: 
       res-config-mysql-update2.patch uploaded by makoto (license 38)

Modified:
    branches/1.8/addons/res_config_mysql.c

Modified: branches/1.8/addons/res_config_mysql.c
URL: http://svnview.digium.com/svn/asterisk/branches/1.8/addons/res_config_mysql.c?view=diff&rev=299583&r1=299582&r2=299583
==============================================================================
--- branches/1.8/addons/res_config_mysql.c (original)
+++ branches/1.8/addons/res_config_mysql.c Fri Dec 24 11:58:30 2010
@@ -745,6 +745,7 @@
 
 		ESCAPE_STRING(buf, newval);
 		ast_str_append(&sql, 0, "%s %s = '%s'", first ? "" : ",", newparam, ast_str_buffer(buf));
+		first = 0;
 
 		/* If the column length isn't long enough, give a chance to lengthen it. */
 		if (strncmp(column->type, "char", 4) == 0 || strncmp(column->type, "varchar", 7) == 0) {




More information about the asterisk-commits mailing list