[asterisk-commits] trunk r16535 - in /trunk: ./ res/res_musiconhold.c

asterisk-commits at lists.digium.com asterisk-commits at lists.digium.com
Thu Mar 30 10:58:17 MST 2006


Author: file
Date: Thu Mar 30 11:58:16 2006
New Revision: 16535

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

........
r16534 | file | 2006-03-30 13:55:28 -0400 (Thu, 30 Mar 2006) | 2 lines

Do not exceed the array size for maximum allowed moh files. (issue #6842)

........

Modified:
    trunk/   (props changed)
    trunk/res/res_musiconhold.c

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

Modified: trunk/res/res_musiconhold.c
URL: http://svn.digium.com/view/asterisk/trunk/res/res_musiconhold.c?rev=16535&r1=16534&r2=16535&view=diff
==============================================================================
--- trunk/res/res_musiconhold.c (original)
+++ trunk/res/res_musiconhold.c Thu Mar 30 11:58:16 2006
@@ -776,6 +776,11 @@
 
 		if (i == class->total_files)
 			strcpy(class->filearray[class->total_files++], filepath);
+
+		/* If the new total files is equal to the maximum allowed, stop adding new ones */
+		if (class->total_files == MAX_MOHFILES)
+			break;
+
 	}
 
 	closedir(files_DIR);



More information about the asterisk-commits mailing list