[asterisk-commits] file: branch 1.4 r88671 - /branches/1.4/channels/chan_sip.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Mon Nov 5 12:47:14 CST 2007


Author: file
Date: Mon Nov  5 12:47:13 2007
New Revision: 88671

URL: http://svn.digium.com/view/asterisk?view=rev&rev=88671
Log:
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

Modified:
    branches/1.4/channels/chan_sip.c

Modified: branches/1.4/channels/chan_sip.c
URL: http://svn.digium.com/view/asterisk/branches/1.4/channels/chan_sip.c?view=diff&rev=88671&r1=88670&r2=88671
==============================================================================
--- branches/1.4/channels/chan_sip.c (original)
+++ branches/1.4/channels/chan_sip.c Mon Nov  5 12:47:13 2007
@@ -4847,7 +4847,7 @@
 /*! \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",




More information about the asterisk-commits mailing list