Commit db326b81 authored by Federico G. Schwindt's avatar Federico G. Schwindt

Polish

parent 7c3ab258
......@@ -140,15 +140,11 @@ vmod_log(VRT_CTX, const char *s, ...)
va_list ap;
CHECK_OBJ_NOTNULL(ctx, VRT_CTX_MAGIC);
WS_Assert(ctx->ws);
u = WS_Reserve(ctx->ws, 0);
t.b = ctx->ws->f;
va_start(ap, s);
t.e = VRT_StringList(ctx->ws->f, u, s, ap);
va_end(ap);
if (t.e != NULL) {
assert(t.e > t.b);
t.e--;
......@@ -168,17 +164,14 @@ vmod_syslog(VRT_CTX, VCL_INT fac, const char *fmt, ...)
txt t;
CHECK_OBJ_NOTNULL(ctx, VRT_CTX_MAGIC);
u = WS_Reserve(ctx->ws, 0);
t.b = ctx->ws->f;
va_start(ap, fmt);
if (ctx->ws != NULL) {
u = WS_Reserve(ctx->ws, 0);
t.b = ctx->ws->f;
t.e = VRT_StringList(ctx->ws->f, u, fmt, ap);
if (t.e != NULL)
syslog((int)fac, "%s", t.b);
WS_Release(ctx->ws, 0);
} else
vsyslog((int)fac, fmt, ap);
t.e = VRT_StringList(ctx->ws->f, u, fmt, ap);
va_end(ap);
if (t.e != NULL)
syslog((int)fac, "%s", t.b);
WS_Release(ctx->ws, 0);
}
VCL_VOID __match_proto__(td_std_collect)
......
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