Commit a5e1865a authored by Nils Goroll's avatar Nils Goroll

change WS_Reserve

parent c9bf6534
......@@ -369,7 +369,7 @@ vmod_set_match(VRT_CTX, struct vmod_re2_set *set, VCL_STRING subject)
}
buf = WS_Front(ctx->ws);
buflen = WS_Reserve(ctx->ws, 0);
buflen = WS_ReserveAll(ctx->ws);
if ((err = vre2set_match(set->set, subject, &match, buf, buflen,
&task->nmatches, &errkind)) != NULL) {
VERR(ctx, ERR_PREFIX "%s", set->vcl_name, subject, err);
......
......@@ -198,7 +198,7 @@ rewritef(VRT_CTX, vre2 * restrict vre2, const rewrite_e mode, VCL_STRING text,
const char *err;
ret = WS_Front(ctx->ws);
bytes = WS_Reserve(ctx->ws, 0);
bytes = WS_ReserveAll(ctx->ws);
if (bytes == 0) {
VERR(ctx, ERR_PREFIX "workspace overflow", rewrite_name[mode],
text, rewrite, fallback);
......@@ -756,7 +756,7 @@ vmod_quotemeta(VRT_CTX, VCL_STRING unquoted, VCL_STRING fallback)
CHECK_OBJ_NOTNULL(ctx, VRT_CTX_MAGIC);
ret = WS_Front(ctx->ws);
bytes = WS_Reserve(ctx->ws, 0);
bytes = WS_ReserveAll(ctx->ws);
if (bytes == 0) {
VERR(ctx, ERR_PREFIX "workspace overflow", unquoted, fallback);
WS_Release(ctx->ws, 0);
......
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