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
18b75e95
Unverified
Commit
18b75e95
authored
Jan 13, 2021
by
Nils Goroll
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add VRT_priv_top_get() to parallel VRT_priv_task_get()
Ref
06cf60a0
parent
104bd724
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
18 additions
and
0 deletions
+18
-0
cache_vrt_priv.c
bin/varnishd/cache/cache_vrt_priv.c
+16
-0
vrt.h
include/vrt.h
+2
-0
No files found.
bin/varnishd/cache/cache_vrt_priv.c
View file @
18b75e95
...
...
@@ -216,6 +216,22 @@ VRT_priv_task(VRT_CTX, const void *vmod_id)
CHECK_OBJ_NOTNULL(req, REQ_MAGIC); \
} while(0)
struct
vmod_priv
*
VRT_priv_top_get
(
VRT_CTX
,
const
void
*
vmod_id
)
{
struct
req
*
req
;
struct
sess
*
sp
;
struct
reqtop
*
top
;
struct
vmod_priv
*
priv
;
VRT_PRIV_TOP_PREP
(
ctx
,
req
,
sp
,
top
);
Lck_Lock
(
&
sp
->
mtx
);
priv
=
vrt_priv_dynamic_get
(
top
->
privs
,
(
uintptr_t
)
vmod_id
);
Lck_Unlock
(
&
sp
->
mtx
);
return
(
priv
);
}
struct
vmod_priv
*
VRT_priv_top
(
VRT_CTX
,
const
void
*
vmod_id
)
{
...
...
include/vrt.h
View file @
18b75e95
...
...
@@ -60,6 +60,7 @@
* VRT_CTX_Assert() added
* VRT_ban_string() signature changed
* VRT_priv_task_get() added
* VRT_priv_top_get() added
* 12.0 (2020-09-15)
* Added VRT_DirectorResolve()
* Added VCL_STRING VRT_BLOB_string(VRT_CTX, VCL_BLOB)
...
...
@@ -600,6 +601,7 @@ void VRT_priv_fini(const struct vmod_priv *p);
struct
vmod_priv
*
VRT_priv_task
(
VRT_CTX
,
const
void
*
vmod_id
);
struct
vmod_priv
*
VRT_priv_task_get
(
VRT_CTX
,
const
void
*
vmod_id
);
struct
vmod_priv
*
VRT_priv_top
(
VRT_CTX
,
const
void
*
vmod_id
);
struct
vmod_priv
*
VRT_priv_top_get
(
VRT_CTX
,
const
void
*
vmod_id
);
/* Stevedore related functions */
int
VRT_Stv
(
const
char
*
nm
);
...
...
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