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
cd55aa7f
Commit
cd55aa7f
authored
May 17, 2015
by
Poul-Henning Kamp
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Make the ban header a multiple of 8 bytes for alignment
parent
0c3eaeb1
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
2 deletions
+3
-2
cache_ban.c
bin/varnishd/cache/cache_ban.c
+3
-2
No files found.
bin/varnishd/cache/cache_ban.c
View file @
cd55aa7f
...
@@ -80,7 +80,7 @@
...
@@ -80,7 +80,7 @@
#define BANS_TIMESTAMP 0
#define BANS_TIMESTAMP 0
#define BANS_LENGTH 8
#define BANS_LENGTH 8
#define BANS_FLAGS 12
#define BANS_FLAGS 12
#define BANS_HEAD_LEN 1
3
#define BANS_HEAD_LEN 1
6
#define BANS_FLAG_REQ (1<<0)
#define BANS_FLAG_REQ (1<<0)
#define BANS_FLAG_OBJ (1<<1)
#define BANS_FLAG_OBJ (1<<1)
...
@@ -514,6 +514,7 @@ BAN_Insert(struct ban *b)
...
@@ -514,6 +514,7 @@ BAN_Insert(struct ban *b)
return
(
ban_ins_error
(
NULL
));
return
(
ban_ins_error
(
NULL
));
}
}
memset
(
b
->
spec
,
0
,
BANS_HEAD_LEN
);
t0
=
VTIM_real
();
t0
=
VTIM_real
();
memcpy
(
b
->
spec
+
BANS_TIMESTAMP
,
&
t0
,
sizeof
t0
);
memcpy
(
b
->
spec
+
BANS_TIMESTAMP
,
&
t0
,
sizeof
t0
);
b
->
spec
[
BANS_FLAGS
]
=
b
->
flags
&
0xff
;
b
->
spec
[
BANS_FLAGS
]
=
b
->
flags
&
0xff
;
...
@@ -832,7 +833,7 @@ ban_evaluate(struct worker *wrk, const uint8_t *bs, struct objcore *oc,
...
@@ -832,7 +833,7 @@ ban_evaluate(struct worker *wrk, const uint8_t *bs, struct objcore *oc,
const
char
*
arg1
;
const
char
*
arg1
;
be
=
bs
+
ban_len
(
bs
);
be
=
bs
+
ban_len
(
bs
);
bs
+=
13
;
bs
+=
BANS_HEAD_LEN
;
while
(
bs
<
be
)
{
while
(
bs
<
be
)
{
(
*
tests
)
++
;
(
*
tests
)
++
;
ban_iter
(
&
bs
,
&
bt
);
ban_iter
(
&
bs
,
&
bt
);
...
...
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