summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMark Michelson <mmichelson@digium.com>2008-06-17 18:09:54 +0000
committerMark Michelson <mmichelson@digium.com>2008-06-17 18:09:54 +0000
commit8c6184f0dad482ded0ad1574449c6ac234c759f6 (patch)
tree3eaaa418aa908aa5e15d2ade3bdd21c09e4f4278
parent0283469cfc3d6eab2666433f04f2fa895a8a34b2 (diff)
Merged revisions 123333 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r123333 | mmichelson | 2008-06-17 13:09:16 -0500 (Tue, 17 Jun 2008) | 11 lines Cisco BTS sends SIP responses with a tab between the Cseq number and SIP request method in the Cseq: header. Asterisk did not handle this properly, but with this patch, all is well. (closes issue #12834) Reported by: tobias_e Patches: 12834.patch uploaded by putnopvut (license 60) Tested by: tobias_e ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@123334 65c4cc65-6c06-0410-ace0-fbb531ad65f3
-rw-r--r--channels/chan_sip.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/channels/chan_sip.c b/channels/chan_sip.c
index 72035ebad..09cc71134 100644
--- a/channels/chan_sip.c
+++ b/channels/chan_sip.c
@@ -16344,12 +16344,12 @@ static void handle_response(struct sip_pvt *p, int resp, char *rest, struct sip_
int sipmethod;
int res = 1;
const char *c = get_header(req, "Cseq");
- const char *msg = strchr(c, ' ');
+ /* Skip the Cseq and its subsequent spaces */
+ const char *msg = ast_skip_blanks(ast_skip_nonblanks((char *)c));
if (!msg)
msg = "";
- else
- msg++;
+
sipmethod = find_sip_method(msg);
owner = p->owner;