]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
storing the route-set also on a 181 response not only on 180,182 or 183.
authorStefan Schmidt <sst@sil.at>
Thu, 13 Oct 2011 06:58:00 +0000 (06:58 +0000)
committerStefan Schmidt <sst@sil.at>
Thu, 13 Oct 2011 06:58:00 +0000 (06:58 +0000)
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@340717 65c4cc65-6c06-0410-ace0-fbb531ad65f3

channels/chan_sip.c

index 438fc5771180e0c6d459769ee42deb52e4997244..95c36d96b7408fda82029e6915fba9f999b3d65a 100644 (file)
@@ -19484,6 +19484,13 @@ static void handle_response_invite(struct sip_pvt *p, int resp, const char *rest
        case 181:       /* Call Is Being Forwarded */
                if (!req->ignore && (p->invitestate != INV_CANCELLED) && sip_cancel_destroy(p))
                        ast_log(LOG_WARNING, "Unable to cancel SIP destruction.  Expect bad things.\n");
+               /* Store Route-set from provisional SIP responses so
+                * early-dialog request can be routed properly
+                * */
+               parse_ok_contact(p, req);
+               if (!reinvite) {
+                       build_route(p, req, 1);
+               }
                if (!req->ignore && p->owner) {
                        struct ast_party_redirecting redirecting;
                        struct ast_set_party_redirecting update_redirecting;