<html><head></head><body><div style="font-family:Helvetica Neue, Helvetica, Arial, sans-serif;font-size:16px;"><div>Hello,</div><div><br></div><div><br></div><div>I have a scenario where caller and callee both place the call on hold and when they both try to un hold the call at the same time , I've noticed FreeSWITCH introducing 5 sec delay to unhold both the legs. I have tracked the 5 second delay in switch_core_media.c to </div><div><span><span style="color: rgb(0, 0, 0); font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; font-size: 16px;">switch_channel_wait_for_flag...</span></span><br></div><div><span><span style="color: rgb(0, 0, 0); font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; font-size: 16px;"><br></span></span></div><div><span style="white-space: pre-wrap;">                  </span><font size="2">if (b_channel) {</font></div><div><font size="2"> <span style="white-space: pre-wrap;">                              </span>if (switch_channel_test_flag(session->channel, CF_HOLD)) {</font></div><div><font size="2"> <span style="white-space: pre-wrap;">                                        </span>switch_ivr_unhold(b_session);</font></div><div><font size="2"> <span style="white-space: pre-wrap;">                                        </span>switch_channel_clear_flag(session->channel, CF_SUSPEND);</font></div><div><font size="2"> <span style="white-space: pre-wrap;">                                  </span>switch_channel_clear_flag(session->channel, CF_HOLD);</font></div><div><font size="2"> <span style="white-space: pre-wrap;">                             </span>} else {</font></div><div><font size="2"> <span style="white-space: pre-wrap;">                                     </span>switch_channel_stop_broadcast(b_channel);</font></div><div><font size="2"> <span style="white-space: pre-wrap;">                                    </span>switch_channel_wait_for_flag(b_channel, CF_BROADCAST, SWITCH_FALSE, 5000, NULL);  </font></div><div><font size="2"> <span style="white-space: pre-wrap;">                         </span>}</font></div><div><font size="2"> <span style="white-space: pre-wrap;">                    </span>}</font></div><div><br></div><div><b><i>switch_channel_wait_for_flag</i></b> is not returning back and its timing out I believe . I am not sure if this a valid bug and I want to understand why  it's not clearing CF_BROADCAST flag on one leg . Any help is appreciated .</div><div><br></div><div>Also, under perfect working scenarios I see "<b><i><font color="#440062">done playing file local_stream://xxx</font></i></b>" on the console , but I dont see this log for the above scenario . </div><div><br></div><div>Appreciate all your help ! <br><br></div><div><br></div><div>Thanks</div><div>Jyotshna</div><div><br></div><div><br></div><br><br></div></body></html>