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/branches/1.4@123333
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
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;