[asterisk-commits] file: branch 1.4 r89592 - /branches/1.4/pbx/pbx_config.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Mon Nov 26 11:36:46 CST 2007


Author: file
Date: Mon Nov 26 11:36:45 2007
New Revision: 89592

URL: http://svn.digium.com/view/asterisk?view=rev&rev=89592
Log:
Use ast_free to free memory, or else we shall implode if MALLOC_DEBUG is enabled.
(closes issue #11347)
Reported by: ys
Patches:
      pbx.pbx_config.c.diff uploaded by ys (license 281)

Modified:
    branches/1.4/pbx/pbx_config.c

Modified: branches/1.4/pbx/pbx_config.c
URL: http://svn.digium.com/view/asterisk/branches/1.4/pbx/pbx_config.c?view=diff&rev=89592&r1=89591&r2=89592
==============================================================================
--- branches/1.4/pbx/pbx_config.c (original)
+++ branches/1.4/pbx/pbx_config.c Mon Nov 26 11:36:45 2007
@@ -1472,7 +1472,7 @@
 	if (!app_data)
 		app_data="";
 	if (ast_add_extension(argv[4], argc == 6 ? 1 : 0, exten, iprior, NULL, cidmatch, app,
-		(void *)strdup(app_data), free, registrar)) {
+		(void *)strdup(app_data), ast_free, registrar)) {
 		switch (errno) {
 		case ENOMEM:
 			ast_cli(fd, "Out of free memory\n");
@@ -1565,7 +1565,7 @@
 	if (!app_data)
 		app_data="";
 	if (ast_add_extension(argv[5], argc == 7 ? 1 : 0, exten, iprior, NULL, cidmatch, app,
-		(void *)strdup(app_data), free, registrar)) {
+		(void *)strdup(app_data), ast_free, registrar)) {
 		switch (errno) {
 		case ENOMEM:
 			ast_cli(fd, "Out of free memory\n");




More information about the asterisk-commits mailing list