diff --git a/channels/chan_sip.c b/channels/chan_sip.c index 88a1593359..e75cf55e9f 100644 --- a/channels/chan_sip.c +++ b/channels/chan_sip.c @@ -8004,7 +8004,7 @@ static int reqprep(struct sip_request *req, struct sip_pvt *p, int sipmethod, in seqno = p->ocseq; } - if (sipmethod == SIP_CANCEL) { + if (sipmethod == SIP_CANCEL || sipmethod == SIP_INVITE) { p->branch = p->invite_branch; build_via(p); } else if (newbranch) {