diff --git a/lib/libpfctl/libpfctl.c b/lib/libpfctl/libpfctl.c index ab49dabe88c..1959f7bebc3 100644 --- a/lib/libpfctl/libpfctl.c +++ b/lib/libpfctl/libpfctl.c @@ -3611,7 +3611,8 @@ static struct snl_attr_parser ap_tstats[] = { { .type = PF_TS_MATCH, .off = _OUT(pfrts_match), .cb = snl_attr_get_uint64 }, {. type = PF_TS_NOMATCH, .off = _OUT(pfrts_nomatch), .cb = snl_attr_get_uint64 }, { .type = PF_TS_TZERO, .off = _OUT(pfrts_tzero), .cb = snl_attr_get_uint64 }, - { .type = PF_TS_REFCNT, .off = _OUT(pfrts_cnt), . arg = (void *)PFR_REFCNT_MAX, .cb = snl_attr_get_uint64_into_int_array }, + { .type = PF_TS_CNT, .off = _OUT(pfrts_cnt), .cb = snl_attr_get_uint64 }, + { .type = PF_TS_REFCNT, .off = _OUT(pfrts_refcnt), . arg = (void *)PFR_REFCNT_MAX, .cb = snl_attr_get_uint64_into_int_array }, }; #undef _OUT SNL_DECLARE_PARSER(tstats_parser, struct genlmsghdr, snl_f_p_empty, ap_tstats); diff --git a/tests/sys/netpfil/pf/table.sh b/tests/sys/netpfil/pf/table.sh index 0b2b5659240..cd83ac90e55 100644 --- a/tests/sys/netpfil/pf/table.sh +++ b/tests/sys/netpfil/pf/table.sh @@ -194,6 +194,10 @@ zero_one_body() jexec alcatraz pfctl -t foo -T show -vv + atf_check -s exit:0 -e ignore \ + -o match:'Addresses: 2' \ + jexec alcatraz pfctl -vvsTables + atf_check -s exit:0 -e ignore \ -o match:'In/Block:.*'"$TABLE_STATS_ZERO_REGEXP" \ -o match:'In/Pass:.*'"$TABLE_STATS_NONZERO_REGEXP" \