From: Mark Spencer Date: Thu, 8 Apr 2004 05:03:47 +0000 (+0000) Subject: Turn off MOH later rather than sooner. X-Git-Tag: 1.0.0-rc1~763 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=6cde9d87a3a4d9735796599cc6e26be1eb08ef81;p=thirdparty%2Fasterisk.git Turn off MOH later rather than sooner. git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@2659 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- diff --git a/apps/app_queue.c b/apps/app_queue.c index 45a82221b3..c4c4d5da7e 100755 --- a/apps/app_queue.c +++ b/apps/app_queue.c @@ -975,8 +975,6 @@ static int try_calling(struct queue_ent *qe, char *options, char *announceoverri recalc_holdtime(qe); update_queue(qe->parent, lpeer); hanguptree(outgoing, peer); - /* Stop music on hold */ - ast_moh_stop(qe->chan); outgoing = NULL; if (announce) { int res2; @@ -994,6 +992,8 @@ static int try_calling(struct queue_ent *qe, char *options, char *announceoverri return -1; } } + /* Stop music on hold */ + ast_moh_stop(qe->chan); /* If appropriate, log that we have a destination channel */ if (qe->chan->cdr) ast_cdr_setdestchan(qe->chan->cdr, peer->name);