diff options
author | Francis Lavoie <lavofr@gmail.com> | 2020-09-22 19:37:15 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-09-22 17:37:15 -0600 |
commit | be6daa5fd46edc9f66a5129347482b38e22bf103 (patch) | |
tree | 4c1bdbb1bb1cabfe90146f674819ebaf3e52759e /caddytest | |
parent | fe27f9cf0c7f53c891c35fbcf6a6b3219e85fd0a (diff) |
httpcaddyfile: Fix panic when parsing route with matchers (#3746)
Fixes #3745
Diffstat (limited to 'caddytest')
-rw-r--r-- | caddytest/integration/caddyfile_adapt/matchers_in_route.txt | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/caddytest/integration/caddyfile_adapt/matchers_in_route.txt b/caddytest/integration/caddyfile_adapt/matchers_in_route.txt new file mode 100644 index 0000000..01609b0 --- /dev/null +++ b/caddytest/integration/caddyfile_adapt/matchers_in_route.txt @@ -0,0 +1,31 @@ +:80 { + route { + # unused matchers should not panic + # see https://github.com/caddyserver/caddy/issues/3745 + @matcher1 path /path1 + @matcher2 path /path2 + } +} +---------- +{ + "apps": { + "http": { + "servers": { + "srv0": { + "listen": [ + ":80" + ], + "routes": [ + { + "handle": [ + { + "handler": "subroute" + } + ] + } + ] + } + } + } + } +}
\ No newline at end of file |