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

Don't overload symbols

parent 9bb435c4
...@@ -12,7 +12,7 @@ varnish v1 -vcl+backend { ...@@ -12,7 +12,7 @@ varnish v1 -vcl+backend {
import vtc; import vtc;
sub vcl_init { sub vcl_init {
new obj = debug.obj(); new objx = debug.obj();
} }
sub vcl_recv { sub vcl_recv {
...@@ -28,8 +28,8 @@ varnish v1 -vcl+backend { ...@@ -28,8 +28,8 @@ varnish v1 -vcl+backend {
set resp.http.not = vtc.typesize("*"); set resp.http.not = vtc.typesize("*");
debug.test_priv_call(); debug.test_priv_call();
debug.test_priv_vcl(); debug.test_priv_vcl();
obj.test_priv_call(); objx.test_priv_call();
obj.test_priv_vcl(); objx.test_priv_vcl();
std.log("VCL" + " initiated " + "log"); std.log("VCL" + " initiated " + "log");
std.syslog(8 + 7, "Somebody runs varnishtest"); std.syslog(8 + 7, "Somebody runs varnishtest");
debug.rot52(resp); debug.rot52(resp);
......
...@@ -12,7 +12,7 @@ varnish v1 -vcl+backend { ...@@ -12,7 +12,7 @@ varnish v1 -vcl+backend {
"127"/24; "127"/24;
} }
acl local { acl locals {
// We assume c1 and s1 comes from same address // We assume c1 and s1 comes from same address
"${s1_addr}"/24; "${s1_addr}"/24;
} }
...@@ -24,7 +24,7 @@ varnish v1 -vcl+backend { ...@@ -24,7 +24,7 @@ varnish v1 -vcl+backend {
} }
sub vcl_recv { sub vcl_recv {
if (debug.match_acl(ip=client.ip, acl=local)) { if (debug.match_acl(ip=client.ip, acl=locals)) {
return (hash); return (hash);
} }
return (synth(500)); return (synth(500));
......
...@@ -13,7 +13,7 @@ varnish v1 -errvcl "Missing dynamic backend address or port" { ...@@ -13,7 +13,7 @@ varnish v1 -errvcl "Missing dynamic backend address or port" {
} }
sub vcl_init { sub vcl_init {
new obj = debug.dyn("", ""); new objx = debug.dyn("", "");
std.log("Should not happen"); std.log("Should not happen");
} }
} }
......
...@@ -9,12 +9,12 @@ varnish v1 -vcl+backend { ...@@ -9,12 +9,12 @@ varnish v1 -vcl+backend {
import debug; import debug;
sub vcl_init { sub vcl_init {
new obj = debug.obj("don't care"); new objx = debug.obj("don't care");
} }
sub vcl_deliver { sub vcl_deliver {
obj.enum(martin); objx.enum(martin);
set resp.http.foo = obj.foo(""); set resp.http.foo = objx.foo("");
} }
} -start } -start
......
...@@ -21,7 +21,7 @@ varnish v1 -vcl+backend { ...@@ -21,7 +21,7 @@ varnish v1 -vcl+backend {
import std; import std;
sub vcl_init { sub vcl_init {
new obj = debug.obj(); new objx = debug.obj();
new vd = directors.shard(); new vd = directors.shard();
debug.test_priv_task("something"); debug.test_priv_task("something");
debug.test_priv_task("to remember"); debug.test_priv_task("to remember");
...@@ -32,7 +32,7 @@ varnish v1 -vcl+backend { ...@@ -32,7 +32,7 @@ varnish v1 -vcl+backend {
vd.reconfigure(replicas=25); vd.reconfigure(replicas=25);
std.log("func " + debug.test_priv_task()); std.log("func " + debug.test_priv_task());
std.log("obj " + obj.test_priv_task()); std.log("obj " + objx.test_priv_task());
} }
sub vcl_recv { sub vcl_recv {
......
...@@ -15,14 +15,14 @@ varnish v1 -arg "-p debug=+vclrel" -vcl+backend { ...@@ -15,14 +15,14 @@ varnish v1 -arg "-p debug=+vclrel" -vcl+backend {
import std; import std;
sub vcl_init { sub vcl_init {
new obj = debug.obj(); new objx = debug.obj();
} }
sub vcl_init { sub vcl_init {
debug.test_priv_task("something"); debug.test_priv_task("something");
debug.test_priv_task("to remember"); debug.test_priv_task("to remember");
std.log("func " + debug.test_priv_task()); std.log("func " + debug.test_priv_task());
std.log("obj " + obj.test_priv_task()); std.log("obj " + objx.test_priv_task());
} }
sub vcl_recv { sub vcl_recv {
...@@ -34,11 +34,11 @@ varnish v1 -arg "-p debug=+vclrel" -vcl+backend { ...@@ -34,11 +34,11 @@ varnish v1 -arg "-p debug=+vclrel" -vcl+backend {
sub vcl_deliver { sub vcl_deliver {
set resp.http.x0 = req.http.x0; set resp.http.x0 = req.http.x0;
set resp.http.x1 = debug.test_priv_task(); set resp.http.x1 = debug.test_priv_task();
set resp.http.o1 = obj.test_priv_task(); set resp.http.o1 = objx.test_priv_task();
} }
sub vcl_backend_fetch { sub vcl_backend_fetch {
obj.test_priv_task("b"); objx.test_priv_task("b");
std.log("foo"); std.log("foo");
set bereq.http.bx0 = debug.test_priv_task(bereq.url); set bereq.http.bx0 = debug.test_priv_task(bereq.url);
std.log("bar"); std.log("bar");
...@@ -47,14 +47,14 @@ varnish v1 -arg "-p debug=+vclrel" -vcl+backend { ...@@ -47,14 +47,14 @@ varnish v1 -arg "-p debug=+vclrel" -vcl+backend {
sub vcl_backend_response { sub vcl_backend_response {
set beresp.http.bx0 = bereq.http.bx0; set beresp.http.bx0 = bereq.http.bx0;
set beresp.http.bx1 = debug.test_priv_task(""); set beresp.http.bx1 = debug.test_priv_task("");
set beresp.http.bo1 = obj.test_priv_task(""); set beresp.http.bo1 = objx.test_priv_task("");
} }
sub vcl_fini { sub vcl_fini {
debug.test_priv_task("cleaning"); debug.test_priv_task("cleaning");
debug.test_priv_task("up"); debug.test_priv_task("up");
std.log("func " + debug.test_priv_task()); std.log("func " + debug.test_priv_task());
std.log("obj " + obj.test_priv_task()); std.log("obj " + objx.test_priv_task());
} }
} -start } -start
......
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