Commit 656aa24b authored by Poul-Henning Kamp's avatar Poul-Henning Kamp

Rename VRT_CollectStrands() to VRT_STRANDS_string()

parent 67fb2265
...@@ -593,7 +593,7 @@ VRT_StrandsWS(struct ws *ws, const char *h, VCL_STRANDS s) ...@@ -593,7 +593,7 @@ VRT_StrandsWS(struct ws *ws, const char *h, VCL_STRANDS s)
*/ */
VCL_STRING VCL_STRING
VRT_CollectStrands(VRT_CTX, VCL_STRANDS s) VRT_STRANDS_string(VRT_CTX, VCL_STRANDS s)
{ {
const char *b; const char *b;
......
...@@ -54,6 +54,7 @@ ...@@ -54,6 +54,7 @@
* binary/load-time compatible, increment MAJOR version * binary/load-time compatible, increment MAJOR version
* *
* NEXT (2021-09-15) * NEXT (2021-09-15)
* VRT_CollectStrands() renamed to VRT_STRANDS_string()
* VRT_l_{beresp|resp}_body() changed to takes STRANDS argument * VRT_l_{beresp|resp}_body() changed to takes STRANDS argument
* VRT_SetHdr() changed to take `const char*` & `STRANDS` arguments. * VRT_SetHdr() changed to take `const char*` & `STRANDS` arguments.
* VRT_UnsetHdr() added * VRT_UnsetHdr() added
...@@ -454,7 +455,6 @@ VCL_BOOL VRT_Strands2Bool(VCL_STRANDS); ...@@ -454,7 +455,6 @@ VCL_BOOL VRT_Strands2Bool(VCL_STRANDS);
uint32_t VRT_HashStrands32(VCL_STRANDS); uint32_t VRT_HashStrands32(VCL_STRANDS);
char *VRT_Strands(char *, size_t, VCL_STRANDS); char *VRT_Strands(char *, size_t, VCL_STRANDS);
VCL_STRING VRT_StrandsWS(struct ws *, const char *, VCL_STRANDS); VCL_STRING VRT_StrandsWS(struct ws *, const char *, VCL_STRANDS);
VCL_STRING VRT_CollectStrands(VRT_CTX, VCL_STRANDS);
VCL_STRING VRT_UpperLowerStrands(VRT_CTX, VCL_STRANDS s, int up); VCL_STRING VRT_UpperLowerStrands(VRT_CTX, VCL_STRANDS s, int up);
/* VCL_SUB */ /* VCL_SUB */
...@@ -471,6 +471,7 @@ VCL_STRING VRT_INT_string(VRT_CTX, VCL_INT); ...@@ -471,6 +471,7 @@ VCL_STRING VRT_INT_string(VRT_CTX, VCL_INT);
VCL_STRING VRT_IP_string(VRT_CTX, VCL_IP); VCL_STRING VRT_IP_string(VRT_CTX, VCL_IP);
VCL_STRING VRT_REAL_string(VRT_CTX, VCL_REAL); VCL_STRING VRT_REAL_string(VRT_CTX, VCL_REAL);
VCL_STRING VRT_STEVEDORE_string(VCL_STEVEDORE); VCL_STRING VRT_STEVEDORE_string(VCL_STEVEDORE);
VCL_STRING VRT_STRANDS_string(VRT_CTX, VCL_STRANDS);
VCL_STRING VRT_TIME_string(VRT_CTX, VCL_TIME); VCL_STRING VRT_TIME_string(VRT_CTX, VCL_TIME);
/* historical */ /* historical */
......
...@@ -184,7 +184,7 @@ const struct type STRANDS[1] = {{ ...@@ -184,7 +184,7 @@ const struct type STRANDS[1] = {{
.magic = TYPE_MAGIC, .magic = TYPE_MAGIC,
.name = "STRANDS", .name = "STRANDS",
.stringform = 1, .stringform = 1,
.tostring = "VRT_CollectStrands(ctx,\v+\n\v1\v-\n)", .tostring = "VRT_STRANDS_string(ctx,\v+\n\v1\v-\n)",
}}; }};
static const struct vcc_method strings_methods[] = { static const struct vcc_method strings_methods[] = {
......
...@@ -470,7 +470,7 @@ vmod_transcode(VRT_CTX, VCL_ENUM decs, VCL_ENUM encs, VCL_ENUM case_s, ...@@ -470,7 +470,7 @@ vmod_transcode(VRT_CTX, VCL_ENUM decs, VCL_ENUM encs, VCL_ENUM case_s,
* overflow. If there is only one string already in the * overflow. If there is only one string already in the
* workspace, then it is re-used. * workspace, then it is re-used.
*/ */
return (VRT_CollectStrands(ctx, strings)); return (VRT_STRANDS_string(ctx, strings));
r = encode(ctx, enc, kase, &b); r = encode(ctx, enc, kase, &b);
return (r); return (r);
......
...@@ -779,7 +779,7 @@ xyzzy_collect(VRT_CTX, VCL_STRANDS s) ...@@ -779,7 +779,7 @@ xyzzy_collect(VRT_CTX, VCL_STRANDS s)
VCL_STRING r; VCL_STRING r;
CHECK_OBJ_NOTNULL(ctx, VRT_CTX_MAGIC); CHECK_OBJ_NOTNULL(ctx, VRT_CTX_MAGIC);
r = VRT_CollectStrands(ctx, s); r = VRT_STRANDS_string(ctx, s);
if (r != NULL && *r != '\0') if (r != NULL && *r != '\0')
AN(WS_Allocated(ctx->ws, r, strlen(r) + 1)); AN(WS_Allocated(ctx->ws, r, strlen(r) + 1));
return (r); return (r);
......
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