[svn-commits] file: branch 1.2 r38654 - /branches/1.2/res/res_musiconhold.c

svn-commits at lists.digium.com svn-commits at lists.digium.com
Tue Aug 1 12:20:05 MST 2006


Author: file
Date: Tue Aug  1 14:20:05 2006
New Revision: 38654

URL: http://svn.digium.com/view/asterisk?rev=38654&view=rev
Log:
Close the stream when file based MOH stop. This won't get rid of their position in the file but it will cause the translation path to be setup again. (issue #7634 reported by asimpson)

Modified:
    branches/1.2/res/res_musiconhold.c

Modified: branches/1.2/res/res_musiconhold.c
URL: http://svn.digium.com/view/asterisk/branches/1.2/res/res_musiconhold.c?rev=38654&r1=38653&r2=38654&view=diff
==============================================================================
--- branches/1.2/res/res_musiconhold.c (original)
+++ branches/1.2/res/res_musiconhold.c Tue Aug  1 14:20:05 2006
@@ -180,6 +180,10 @@
 	struct moh_files_state *state = chan->music_state;
 
 	if (chan && state) {
+		if (chan->stream) {
+                        ast_closestream(chan->stream);
+                        chan->stream = NULL;
+                }
 		if (option_verbose > 2)
 			ast_verbose(VERBOSE_PREFIX_3 "Stopped music on hold on %s\n", chan->name);
 



More information about the svn-commits mailing list