Skip to content
Permalink
Browse files

Move vtc.panic to STRANDS

  • Loading branch information...
Dridi committed Jul 3, 2019
1 parent bbf53b8 commit 8790bec16d68c2098dc99d9ed27819d24759648c
Showing with 3 additions and 6 deletions.
  1. +1 −1 lib/libvmod_vtc/vmod.vcc
  2. +2 −5 lib/libvmod_vtc/vmod_vtc.c
@@ -70,7 +70,7 @@ $Function IP no_ip()

Returns a null IP address, not even a bogo_ip.

$Function VOID panic(STRING_LIST)
$Function VOID panic(STRANDS)

It can be useful to crash the child process in order to test the robustness
of a VMOD.
@@ -99,16 +99,13 @@ vmod_no_ip(VRT_CTX)
/*--------------------------------------------------------------------*/

VCL_VOID v_matchproto_(td_vtc_panic)
vmod_panic(VRT_CTX, const char *str, ...)
vmod_panic(VRT_CTX, VCL_STRANDS str)
{
va_list ap;
const char *b;

CHECK_OBJ_NOTNULL(ctx, VRT_CTX_MAGIC);

va_start(ap, str);
b = VRT_String(ctx->ws, "PANIC: ", str, ap);
va_end(ap);
b = VRT_StrandsWS(ctx->ws, "PANIC:", str);
VAS_Fail("VCL", "", 0, b, VAS_VCL);
}

0 comments on commit 8790bec

Please sign in to comment.
You can’t perform that action at this time.