If a SIP channel is put on hold multiple times do not keep incrementing the onHold value.

(closes issue #11085)
Reported by: francesco_r
Tested by: blitzrage
(closes issue #10474)
Reported by: acennami


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@88671 65c4cc65-6c06-0410-ace0-fbb531ad65f3
1.4
Joshua Colp 19 years ago
parent a3af50b67d
commit 10c172eb00

@ -4847,7 +4847,7 @@ static int find_sdp(struct sip_request *req)
/*! \brief Change hold state for a call */
static void change_hold_state(struct sip_pvt *dialog, struct sip_request *req, int holdstate, int sendonly)
{
if (global_notifyhold)
if (global_notifyhold && (!holdstate || !ast_test_flag(&dialog->flags[1], SIP_PAGE2_CALL_ONHOLD)))
sip_peer_hold(dialog, holdstate);
if (global_callevents)
manager_event(EVENT_FLAG_CALL, holdstate ? "Hold" : "Unhold",

Loading…
Cancel
Save