[svn-commits] tilghman: branch 1.6.2 r272333 - in /branches/1.6.2: ./ res/res_musiconhold.c

SVN commits to the Digium repositories svn-commits at lists.digium.com
Wed Jun 23 16:55:04 CDT 2010


Author: tilghman
Date: Wed Jun 23 16:54:59 2010
New Revision: 272333

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=272333
Log:
Merged revisions 272332 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/trunk

........
  r272332 | tilghman | 2010-06-23 16:53:49 -0500 (Wed, 23 Jun 2010) | 8 lines
  
  If there is realtime configuration, it does not get re-read on reload unless the config file also changes.
  
  (closes issue #16982)
   Reported by: dmitri
   Patches: 
         res_musiconhold.patch uploaded by dmitri (license 1001)
   Tested by: atis
........

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

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

Modified: branches/1.6.2/res/res_musiconhold.c
URL: http://svnview.digium.com/svn/asterisk/branches/1.6.2/res/res_musiconhold.c?view=diff&rev=272333&r1=272332&r2=272333
==============================================================================
--- branches/1.6.2/res/res_musiconhold.c (original)
+++ branches/1.6.2/res/res_musiconhold.c Wed Jun 23 16:54:59 2010
@@ -1577,6 +1577,10 @@
 	cfg = ast_config_load("musiconhold.conf", config_flags);
 
 	if (cfg == CONFIG_STATUS_FILEMISSING || cfg == CONFIG_STATUS_FILEUNCHANGED || cfg == CONFIG_STATUS_FILEINVALID) {
+		if (ast_check_realtime("musiconhold") && reload) {
+			ao2_t_callback(mohclasses, OBJ_NODATA, moh_class_mark, NULL, "Mark deleted classes");
+			ao2_t_callback(mohclasses, OBJ_UNLINK | OBJ_NODATA | OBJ_MULTIPLE, moh_classes_delete_marked, NULL, "Purge marked classes");
+		}
 		return 0;
 	}
 
@@ -1799,7 +1803,7 @@
 		return AST_MODULE_LOAD_DECLINE;
 	}
 
-	if (!load_moh_classes(0)) { 	/* No music classes configured, so skip it */
+	if (!load_moh_classes(0) && ast_check_realtime("musiconhold") == 0) { 	/* No music classes configured, so skip it */
 		ast_log(LOG_WARNING, "No music on hold classes configured, "
 				"disabling music on hold.\n");
 	} else {




More information about the svn-commits mailing list