[asterisk-commits] russell: branch 1.4 r75108 - in /branches/1.4: ./ res/res_musiconhold.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Fri Jul 13 15:36:16 CDT 2007


Author: russell
Date: Fri Jul 13 15:36:16 2007
New Revision: 75108

URL: http://svn.digium.com/view/asterisk?view=rev&rev=75108
Log:
Merged revisions 75107 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r75107 | russell | 2007-07-13 15:35:22 -0500 (Fri, 13 Jul 2007) | 3 lines

Fix a couple potential minor memory leaks.  load_moh_classes() could return
without destroying the loaded configuration.

........

Modified:
    branches/1.4/   (props changed)
    branches/1.4/res/res_musiconhold.c

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

Modified: branches/1.4/res/res_musiconhold.c
URL: http://svn.digium.com/view/asterisk/branches/1.4/res/res_musiconhold.c?view=diff&rev=75108&r1=75107&r2=75108
==============================================================================
--- branches/1.4/res/res_musiconhold.c (original)
+++ branches/1.4/res/res_musiconhold.c Fri Jul 13 15:36:16 2007
@@ -1065,7 +1065,7 @@
 				*args++ = '\0';
 			if (!(get_mohbyname(var->name, 0))) {			
 				if (!(class = moh_class_malloc())) {
-					return numclasses;
+					break;
 				}
 				
 				ast_copy_string(class->name, var->name, sizeof(class->name));
@@ -1091,7 +1091,7 @@
 			if (args)
 				*args++ = '\0';			
 			if (!(class = moh_class_malloc())) {
-				return numclasses;
+				break;
 			}
 			
 			ast_copy_string(class->name, var->name, sizeof(class->name));




More information about the asterisk-commits mailing list