Commit f58469a7 authored by Poul-Henning Kamp's avatar Poul-Henning Kamp

Reserve "VPI_" for functions which only VCC is allowed to call.

parent 96da1204
......@@ -325,7 +325,7 @@ VRT_count(VRT_CTX, unsigned u)
}
VCL_VCL
VRT_vcl_get(VRT_CTX, const char *name)
VPI_vcl_get(VRT_CTX, const char *name)
{
VCL_VCL vcl;
......@@ -339,7 +339,7 @@ VRT_vcl_get(VRT_CTX, const char *name)
}
void
VRT_vcl_rel(VRT_CTX, VCL_VCL vcl)
VPI_vcl_rel(VRT_CTX, VCL_VCL vcl)
{
CHECK_OBJ_NOTNULL(ctx, VRT_CTX_MAGIC);
AN(vcl);
......@@ -349,7 +349,7 @@ VRT_vcl_rel(VRT_CTX, VCL_VCL vcl)
}
void
VRT_vcl_select(VRT_CTX, VCL_VCL vcl)
VPI_vcl_select(VRT_CTX, VCL_VCL vcl)
{
struct req *req = ctx->req;
......
......@@ -62,6 +62,10 @@ VLU
Varnish Line Up -- library functions to collect stream of bytes
into lines for processing. (lib/libvarnish/vlu.c)
VPI
VCC Private Interface -- functions in varnishd which only VCC is
allowed to call.
VRE
Varnish Regular Expression -- library functions for regular expression
based matching and substring replacement. (lib/libvarnish/vre.c)
......
......@@ -33,6 +33,6 @@
* NB: When this file is changed, lib/libvcc/generate.py *MUST* be rerun.
*/
VCL_VCL VRT_vcl_get(VRT_CTX, const char *);
void VRT_vcl_rel(VRT_CTX, VCL_VCL);
void VRT_vcl_select(VRT_CTX, VCL_VCL);
VCL_VCL VPI_vcl_get(VRT_CTX, const char *);
void VPI_vcl_rel(VRT_CTX, VCL_VCL);
void VPI_vcl_select(VRT_CTX, VCL_VCL);
......@@ -284,12 +284,12 @@ vcc_act_return_vcl(struct vcc *tl)
p = New_IniFin(tl);
AN(p);
VSB_printf(p->ini, "\t%s = VRT_vcl_get(ctx, \"%s\");",
VSB_printf(p->ini, "\t%s = VPI_vcl_get(ctx, \"%s\");",
buf, sym->name);
VSB_printf(p->fin, "\tVRT_vcl_rel(ctx, %s);",
VSB_printf(p->fin, "\tVPI_vcl_rel(ctx, %s);",
buf);
}
Fb(tl, 1, "VRT_vcl_select(ctx, %s);\t/* %s */\n",
Fb(tl, 1, "VPI_vcl_select(ctx, %s);\t/* %s */\n",
(const char*)sym->eval_priv, sym->name);
SkipToken(tl, ')');
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment