From: Olle Johansson Date: Wed, 6 Dec 2006 12:27:43 +0000 (+0000) Subject: Don't send Contact on MESSAGE X-Git-Tag: 1.4.0-beta4~24 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=0fe91149aed14605e3d8ae51a61a3a08a6ed6373;p=thirdparty%2Fasterisk.git Don't send Contact on MESSAGE git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@48317 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- diff --git a/channels/chan_sip.c b/channels/chan_sip.c index ccf3911ea4..ea92c33643 100644 --- a/channels/chan_sip.c +++ b/channels/chan_sip.c @@ -5629,9 +5629,10 @@ static int reqprep(struct sip_request *req, struct sip_pvt *p, int sipmethod, in add_header(req, "From", ot); add_header(req, "To", of); } - /* Do not add Contact for BYE and Cancel requests */ - if (sipmethod != SIP_BYE && sipmethod != SIP_CANCEL) + /* Do not add Contact for MESSAGE, BYE and Cancel requests */ + if (sipmethod != SIP_BYE && sipmethod != SIP_CANCEL && sipmethod != SIP_MESSAGE) add_header(req, "Contact", p->our_contact); + copy_header(req, orig, "Call-ID"); add_header(req, "CSeq", tmp);