Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
A
asterisk
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Issue analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Voice
asterisk
Commits
b2b6f28a
Commit
b2b6f28a
authored
5 years ago
by
Joshua Colp
Committed by
Gerrit Code Review
5 years ago
Browse files
Options
Downloads
Plain Diff
Merge "pjproject_bundled: Allow brackets in via parameters"
parents
7c5a6efb
9d9bde76
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
third-party/pjproject/patches/0040-brackets-in-via-received-params.patch
+40
-0
40 additions, 0 deletions
...roject/patches/0040-brackets-in-via-received-params.patch
with
40 additions
and
0 deletions
third-party/pjproject/patches/0040-brackets-in-via-received-params.patch
0 → 100644
+
40
−
0
View file @
b2b6f28a
From 6324760c2fb0ffeb2e29c6c0a96a33906caa8d5f Mon Sep 17 00:00:00 2001
From: Sean Bright <sean.bright@gmail.com>
Date: Thu, 16 Jan 2020 10:46:11 -0500
Subject: [PATCH] sip_parser.c: Allow brackets in via parameters
From RFC 5118 section 4.5:
While it would be beneficial if the same non-terminal
("IPv6reference") was used for both the "sent-by" and "via-received"
production rules, there has not been a consensus in the working group
to that effect. Thus, the best that can be suggested is that
implementations must follow the Robustness Principle [RFC1122] and be
liberal in accepting a "received" parameter with or without the
delimiting "[" and "]" tokens. When sending a request,
implementations must not put the delimiting "[" and "]" tokens.
---
pjsip/src/pjsip/sip_parser.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/pjsip/src/pjsip/sip_parser.c b/pjsip/src/pjsip/sip_parser.c
index e01e672fb..4f9c7fca4 100644
--- a/pjsip/src/pjsip/sip_parser.c
+++ b/pjsip/src/pjsip/sip_parser.c
@@ -384,11 +384,11 @@
static pj_status_t init_parser()
status = pj_cis_dup(&pconst.pjsip_VIA_PARAM_SPEC, &pconst.pjsip_TOKEN_SPEC);
PJ_ASSERT_RETURN(status == PJ_SUCCESS, status);
- pj_cis_add_str(&pconst.pjsip_VIA_PARAM_SPEC, ":");
+ pj_cis_add_str(&pconst.pjsip_VIA_PARAM_SPEC, "[:]");
status = pj_cis_dup(&pconst.pjsip_VIA_PARAM_SPEC_ESC, &pconst.pjsip_TOKEN_SPEC_ESC);
PJ_ASSERT_RETURN(status == PJ_SUCCESS, status);
- pj_cis_add_str(&pconst.pjsip_VIA_PARAM_SPEC_ESC, ":");
+ pj_cis_add_str(&pconst.pjsip_VIA_PARAM_SPEC_ESC, "[:]");
status = pj_cis_dup(&pconst.pjsip_HOST_SPEC, &pconst.pjsip_ALNUM_SPEC);
PJ_ASSERT_RETURN(status == PJ_SUCCESS, status);
--
2.20.1
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment