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
4127a37a
Commit
4127a37a
authored
Feb 04, 2021
by
Poul-Henning Kamp
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add VRT_synth_blob(). Rename VRT_synth_page() to VRT_synth_strands()
(VRT_synth_page() still works, but is now deprecated.)
parent
d58c4baf
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
24 additions
and
4 deletions
+24
-4
cache_vrt.c
bin/varnishd/cache/cache_vrt.c
+17
-1
vrt.h
include/vrt.h
+6
-2
vcc_action.c
lib/libvcc/vcc_action.c
+1
-1
No files found.
bin/varnishd/cache/cache_vrt.c
View file @
4127a37a
...
...
@@ -817,7 +817,7 @@ VRT_Rollback(VRT_CTX, VCL_HTTP hp)
/*--------------------------------------------------------------------*/
VCL_VOID
VRT_synth_
page
(
VRT_CTX
,
VCL_STRANDS
s
)
VRT_synth_
strands
(
VRT_CTX
,
VCL_STRANDS
s
)
{
struct
vsb
*
vsb
;
int
i
;
...
...
@@ -832,6 +832,22 @@ VRT_synth_page(VRT_CTX, VCL_STRANDS s)
}
}
VCL_VOID
VRT_synth_blob
(
VRT_CTX
,
VCL_BLOB
b
)
{
struct
vsb
*
vsb
;
CAST_OBJ_NOTNULL
(
vsb
,
ctx
->
specific
,
VSB_MAGIC
);
if
(
b
->
len
>
0
&&
b
->
blob
!=
NULL
)
VSB_bcat
(
vsb
,
b
->
blob
,
b
->
len
);
}
VCL_VOID
VRT_synth_page
(
VRT_CTX
,
VCL_STRANDS
s
)
{
VRT_synth_strands
(
ctx
,
s
);
}
/*--------------------------------------------------------------------*/
static
VCL_STRING
...
...
include/vrt.h
View file @
4127a37a
...
...
@@ -53,6 +53,8 @@
* binary/load-time compatible, increment MAJOR version
*
* 13.0 (2021-03-15)
* Move VRT_synth_page() to deprecated status
* Add VRT_synth_strands() and VRT_synth_blob()
* struct vrt_type now produced by generate.py
* VRT_acl_log() moved to VPI_acl_log()
* VRT_Endpoint_Clone() added.
...
...
@@ -546,7 +548,8 @@ VCL_VOID VRT_hashdata(VRT_CTX, VCL_STRANDS);
VCL_VOID
VRT_Rollback
(
VRT_CTX
,
VCL_HTTP
);
/* Synthetic pages */
VCL_VOID
VRT_synth_page
(
VRT_CTX
,
VCL_STRANDS
);
VCL_VOID
VRT_synth_strands
(
VRT_CTX
,
VCL_STRANDS
);
VCL_VOID
VRT_synth_blob
(
VRT_CTX
,
VCL_BLOB
);
/***********************************************************************
* VDI - Director API
...
...
@@ -646,9 +649,10 @@ struct vclref * VRT_VCL_Prevent_Discard(VRT_CTX, const char *);
void
VRT_VCL_Allow_Discard
(
struct
vclref
**
);
/***********************************************************************
* Deprecated interfaces, do not use
* Deprecated interfaces, do not use
, they will disappear at some point.
*/
VCL_VOID
VRT_synth_page
(
VRT_CTX
,
VCL_STRANDS
);
extern
const
void
*
const
vrt_magic_string_end
;
extern
const
void
*
const
vrt_magic_string_unset
;
int
VRT_Stv
(
const
char
*
nm
);
lib/libvcc/vcc_action.c
View file @
4127a37a
...
...
@@ -387,7 +387,7 @@ vcc_act_synthetic(struct vcc *tl, struct token *t, struct symbol *sym)
ERRCHK
(
tl
);
vcc_NextToken
(
tl
);
Fb
(
tl
,
1
,
"VRT_synth_
page
(ctx, "
);
Fb
(
tl
,
1
,
"VRT_synth_
strands
(ctx, "
);
vcc_Expr
(
tl
,
STRANDS
);
ERRCHK
(
tl
);
Fb
(
tl
,
1
,
");
\n
"
);
...
...
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