Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
varnish-cache
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
varnishcache
varnish-cache
Commits
4e3aa514
Commit
4e3aa514
authored
Aug 27, 2014
by
Poul-Henning Kamp
Committed by
Lasse Karstensen
Jan 27, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Escape question marks in C-strings to avoid accidentally generating
tri-graphs. Fixes #1566
parent
1c64de28
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
0 deletions
+10
-0
r01566.vtc
bin/varnishtest/tests/r01566.vtc
+9
-0
vcc_compile.c
lib/libvcc/vcc_compile.c
+1
-0
No files found.
bin/varnishtest/tests/r01566.vtc
0 → 100644
View file @
4e3aa514
varnishtest "escape issue in regexp"
varnish v1 -vcl {
backend b1 { .host = "127.0.0.1"; }
sub vcl_recv {
set req.url = regsuball(req.url, "\??(p|pi)=.*?(&|$)", "");
}
}
lib/libvcc/vcc_compile.c
View file @
4e3aa514
...
...
@@ -211,6 +211,7 @@ EncString(struct vsb *sb, const char *b, const char *e, int mode)
VSB_cat
(
sb
,
"
\"
"
);
for
(;
b
<
e
;
b
++
)
{
switch
(
*
b
)
{
case
'?'
:
// Trigraphs
case
'\\'
:
case
'"'
:
VSB_printf
(
sb
,
"
\\
%c"
,
*
b
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment