Use $Restrict

parent 3b80dbce
......@@ -123,10 +123,7 @@ vmod_set_level(VRT_CTX, VCL_INT level)
default_level = level;
return;
}
if (ctx->method & VCL_MET_TASK_H) {
VRT_fail(ctx, "set_level can not be called here");
return;
}
AZ(ctx->method & VCL_MET_TASK_H);
AN(ctx->method & (VCL_MET_TASK_C | VCL_MET_TASK_B));
zft = get_zipflow_task(ctx);
......
......@@ -39,6 +39,8 @@ Example
$Function VOID set_level(INT level)
$Restrict vcl_init client backend
Set the (default) compression level for the zipflow filter.
Valid values for `level` are -1 to select the default compression
......
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