diff --git a/apps/app_dial.c b/apps/app_dial.c index 81384a716fe6f11c1f3dc31c22fd5a64ceb26017..0d30ebf4186be9686c3fbbd2caa57891827e0712 100644 --- a/apps/app_dial.c +++ b/apps/app_dial.c @@ -1550,7 +1550,7 @@ static struct ast_channel *wait_for_answer(struct ast_channel *in, && CAN_EARLY_BRIDGE(peerflags, in, c)) { ast_channel_early_bridge(in, c); } - if (!ast_test_flag64(outgoing, OPT_MUSICBACK) && ast_strlen_zero(opt_args[OPT_ARG_RINGBACK])) { + if (!(pa->sentringing) && !ast_test_flag64(outgoing, OPT_MUSICBACK) && ast_strlen_zero(opt_args[OPT_ARG_RINGBACK])) { ast_indicate(in, f->subclass.integer); @@ -1587,6 +1587,7 @@ static struct ast_channel *wait_for_answer(struct ast_channel *in, if (single || (!single && !pa->sentringing)) { ast_channel_codec_set(in, ast_channel_codec_get(c)); //for early media codec sync ast_indicate(in, AST_CONTROL_PROGRESS); + pa->sentringing = 0; } } if (!sent_progress) {