Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
U
unique-xids
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
uplex-varnish
unique-xids
Commits
a9e5d350
Commit
a9e5d350
authored
Jun 04, 2012
by
Poul-Henning Kamp
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Increase the id field in VSM to 128 bytes to make space for
64 backend VCL name + IPv4, IPv6 and portnumber. Fixes #1144
parent
5011af25
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
46 additions
and
1 deletion
+46
-1
r01144.vtc
bin/varnishtest/tests/r01144.vtc
+38
-0
vsm_int.h
include/vapi/vsm_int.h
+1
-1
vcc_backend.c
lib/libvcl/vcc_backend.c
+7
-0
No files found.
bin/varnishtest/tests/r01144.vtc
0 → 100644
View file @
a9e5d350
varnishtest "very long backend names"
server s1 {
rxreq
txresp
} -start
varnish v1 -vcl+backend {
backend fedcba9876543210fedcba9876543210fedcba9876543210fedcba9876543210
{
.host = "127.0.0.1";
.port = "54321";
}
sub vcl_recv {
if (req.url == "never") {
set req.backend = fedcba9876543210fedcba9876543210fedcba9876543210fedcba9876543210;
}
}
} -start
client c1 {
txreq
rxresp
expect resp.status == 200
} -run
varnish v1 -badvcl {
backend 0fedcba9876543210fedcba9876543210fedcba9876543210fedcba9876543210
{
.host = "127.0.0.1";
.port = "54321";
}
sub vcl_recv {
if (req.url == "never") {
set req.backend = fedcba9876543210fedcba9876543210fedcba9876543210fedcba9876543210;
}
}
}
include/vapi/vsm_int.h
View file @
a9e5d350
...
...
@@ -104,7 +104,7 @@ struct VSM_chunk {
ssize_t
next
;
/* Offset in shmem */
char
class
[
8
];
char
type
[
8
];
char
ident
[
64
];
char
ident
[
128
];
};
struct
VSM_head
{
...
...
lib/libvcl/vcc_backend.c
View file @
a9e5d350
...
...
@@ -706,6 +706,13 @@ vcc_ParseDirector(struct vcc *tl)
vcc_ExpectCid
(
tl
);
/* ID: name */
ERRCHK
(
tl
);
if
(
tl
->
t
->
e
-
tl
->
t
->
b
>
64
)
{
VSB_printf
(
tl
->
sb
,
"Name of %.*s too long (max 64, is %zd):
\n
"
,
PF
(
t_first
),
(
tl
->
t
->
e
-
tl
->
t
->
b
));
vcc_ErrWhere
(
tl
,
tl
->
t
);
return
;
}
tl
->
t_dir
=
tl
->
t
;
vcc_NextToken
(
tl
);
...
...
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