pfr_fix_anchor() strips leading slashes from table anchors but not
trailing or repeated ones. pf_find_or_create_kruleset() ignores those,
so a table added as "foo/bar/" lands in ruleset "foo/bar" but keeps
"foo/bar/" as its anchor. pfr_table_count() and pfr_skip_table() then
disagree, and with INVARIANTS:
# pfctl -a foo/bar/ -t t -T add 192.0.2.1 # pfctl -a foo/bar -sT panic: pfr_get_tables: corruption detected (1)
"foo//bar" does the same once "foo" exists, and pfctl -vsT hits the
same check in pfr_get_tstats().
Loading rules into such an anchor already fails with EINVAL, since
pf_find_kruleset() doesn't find it. Reject it for tables as well.
Sponsored by: Advanced Micro Devices, Inc.
Signed-off-by: Osvaldo Janeri Filho <ojanerif@amd.com>