aboutsummaryrefslogtreecommitdiffstats
path: root/channels
diff options
context:
space:
mode:
authorfile <file@f38db490-d61c-443f-a65b-d21fe96a405b>2007-11-05 18:47:13 +0000
committerfile <file@f38db490-d61c-443f-a65b-d21fe96a405b>2007-11-05 18:47:13 +0000
commitad65617a2608d833178fe0401d2be9fc84a6dda3 (patch)
treeaee669e81496b235f5ca76218f6adf8e035d871d /channels
parent577d6170beff5e8f0f2cf6f30442c4a36659fd70 (diff)
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: http://svn.digium.com/svn/asterisk/branches/1.4@88671 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'channels')
-rw-r--r--channels/chan_sip.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/channels/chan_sip.c b/channels/chan_sip.c
index 5fba75f36..f65369e9b 100644
--- a/channels/chan_sip.c
+++ b/channels/chan_sip.c
@@ -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",