icseq increments only on requests, not responses (bug #3798)
authorMark Spencer <markster@digium.com>
Sat, 19 Mar 2005 23:40:19 +0000 (23:40 +0000)
committerMark Spencer <markster@digium.com>
Sat, 19 Mar 2005 23:40:19 +0000 (23:40 +0000)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@5208 65c4cc65-6c06-0410-ace0-fbb531ad65f3

channels/chan_sip.c

index 6029b79..8c80bd6 100755 (executable)
@@ -8597,12 +8597,6 @@ static int handle_request(struct sip_pvt *p, struct sip_request *req, struct soc
                        ignore=1;
                }
        
-               if (seqno >= p->icseq)
-                       /* Next should follow monotonically (but not necessarily 
-                          incrementally -- thanks again to the genius authors of SIP --
-                          increasing */
-                       p->icseq = seqno;
-
                extract_uri(p, req);
                while(*e && (*e < 33)) 
                        e++;
@@ -8631,6 +8625,12 @@ static int handle_request(struct sip_pvt *p, struct sip_request *req, struct soc
                ignore=1;
        }
                
+       if (seqno >= p->icseq)
+               /* Next should follow monotonically (but not necessarily 
+                  incrementally -- thanks again to the genius authors of SIP --
+                  increasing */
+               p->icseq = seqno;
+
        /* Find their tag if we haven't got it */
        if (ast_strlen_zero(p->theirtag)) {
                from = get_header(req, "From");