Commit cf4da228 authored by Poul-Henning Kamp's avatar Poul-Henning Kamp

Reimplement param log_hashstring using vsl_mask

XXX: doc-update needed
parent 71a18061
......@@ -169,8 +169,7 @@ HSH_AddString(struct req *req, const char *str)
SHA256_Update(req->sha256ctx, str, l);
SHA256_Update(req->sha256ctx, "#", 1);
if (cache_param->log_hash)
VSLb(req->vsl, SLT_Hash, "%s", str);
VSLb(req->vsl, SLT_Hash, "%s", str);
}
/*---------------------------------------------------------------------
......
......@@ -144,9 +144,6 @@ struct params {
/* Control diagnostic code */
unsigned diag_bitmap;
/* Log hash string to shm */
unsigned log_hash;
/* Log local socket address to shm */
unsigned log_local_addr;
......
......@@ -1033,10 +1033,6 @@ static const struct parspec input_parspec[] = {
"more sessions take a detour around the waiter.",
EXPERIMENTAL,
"0.050", "seconds" },
{ "log_hashstring", tweak_bool, &mgt_param.log_hash, 0, 0,
"Log the hash string components to shared memory log.\n",
0,
"on", "bool" },
{ "log_local_address", tweak_bool, &mgt_param.log_local_addr, 0, 0,
"Log the local address on the TCP connection in the "
"SessionOpen VSL record.\n"
......
......@@ -82,6 +82,7 @@ tweak_vsl_mask(struct cli *cli, const struct parspec *par, const char *arg)
if (!strcmp(arg, "default")) {
(void)vsl_bit(SLT_VCL_trace, BSET);
(void)vsl_bit(SLT_WorkThread, BSET);
(void)vsl_bit(SLT_Hash, BSET);
} else if (*arg != 0) {
av = VAV_Parse(arg, &n, ARGV_COMMA);
if (av[0] != NULL) {
......@@ -118,7 +119,7 @@ tweak_vsl_mask(struct cli *cli, const struct parspec *par, const char *arg)
}
} else {
s = "";
for (j = 0; j < 256; j++) {
for (j = 0; j < (unsigned)SLT_Reserved; j++) {
if (vsl_bit(j, BTST)) {
VCLI_Out(cli, "%s-%s", s, VSL_tags[j]);
s = ",";
......
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