Merged revisions 101152 via svnmerge from
[asterisk/asterisk.git] / channels / chan_sip.c
index 919dd35..d6f4a05 100644 (file)
@@ -15430,7 +15430,9 @@ static int sip_park(struct ast_channel *chan1, struct ast_channel *chan2, struct
 static void ast_quiet_chan(struct ast_channel *chan) 
 {
        if (chan && chan->_state == AST_STATE_UP) {
-               if (chan->generatordata)
+               if (ast_test_flag(chan, AST_FLAG_MOH))
+                       ast_moh_stop(chan);
+               else if (chan->generatordata)
                        ast_deactivate_generator(chan);
        }
 }