[asterisk-bugs] [Asterisk 0010139]: When removing a class from musiconhold.conf and reloading the module, the class is not removed from memory

noreply at bugs.digium.com noreply at bugs.digium.com
Thu Aug 16 16:17:47 CDT 2007


A NOTE has been added to this issue. 
====================================================================== 
http://bugs.digium.com/view.php?id=10139 
====================================================================== 
Reported By:                blitzrage
Assigned To:                russell
====================================================================== 
Project:                    Asterisk
Issue ID:                   10139
Category:                   Resources/res_musiconhold
Reproducibility:            always
Severity:                   minor
Priority:                   normal
Status:                     assigned
Asterisk Version:           1.4.6 
SVN Branch (only for SVN checkouts, not tarball releases): N/A  
SVN Revision (number only!):  
Disclaimer on File?:        N/A 
Request Review:              
====================================================================== 
Date Submitted:             07-06-2007 14:16 CDT
Last Modified:              08-16-2007 16:17 CDT
====================================================================== 
Summary:                    When removing a class from musiconhold.conf and
reloading the module, the class is not removed from memory
Description: 
This happens when loading from extconfig.conf as well, but since it happens
in the flatfile, I'll assume it's the same problem in both cases.

If I add a new class to musiconhold.conf, then run 'module reload
res_musiconhold.so' from the *CLI, then the class is added.

If I remove the class from the musiconhold.conf file, then reload
res_musiconhold.so, then the class is not removed from memory (only a
restart will remove it).
====================================================================== 

---------------------------------------------------------------------- 
 jamesgolovich - 08-16-07 16:17  
---------------------------------------------------------------------- 
So heres the deal. asterisk-10139.diff.txt is the simple patch that just
makes "module reload app_musiconhold.so" behave just like "moh reload". 
There are 2 downsides to it

http://bugs.digium.com/view.php?id=1 it exposed the bug that when you use one of
the apps to start MOH if
you reload in the middle it reverts your MOH back to 'default' even if
there were no changes.
http://bugs.digium.com/view.php?id=2 every moh in progress is stopped and
restarted when the reload happens

The upside is that its extremely simple and doesn't cause any extra
locking of the big list.

The asterisk-10139-advanced.diff.txt is the more complicated version that
doesn't have those two issues.  It basically flags channels to be deleted
and if they aren't in use deletes them right away, or if they are in use
they will be deleted when the last channel that is using them exits.  The
downside is that its more complicated and has a few more locks happening. 

Issue History 
Date Modified   Username       Field                    Change               
====================================================================== 
08-16-07 16:17  jamesgolovich  Note Added: 0068954                          
======================================================================




More information about the asterisk-bugs mailing list