From: sashan Date: Thu, 16 Jun 2022 20:47:26 +0000 (+0000) Subject: pfctl reports existing table as being added. glitch has X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=9339d28aec66ec1a8e8f26a4f068b3b817c153ff;p=openbsd pfctl reports existing table as being added. glitch has been spotted and reported by jmc@ OK kn@ --- diff --git a/sys/net/pf_table.c b/sys/net/pf_table.c index f261baef963..c40505675bd 100644 --- a/sys/net/pf_table.c +++ b/sys/net/pf_table.c @@ -1,4 +1,4 @@ -/* $OpenBSD: pf_table.c,v 1.141 2022/06/07 22:14:15 sashan Exp $ */ +/* $OpenBSD: pf_table.c,v 1.142 2022/06/16 20:47:26 sashan Exp $ */ /* * Copyright (c) 2002 Cedric Berger @@ -1562,13 +1562,13 @@ pfr_add_tables(struct pfr_table *tbl, int size, int *nadd, int flags) if (p == NULL) { SLIST_REMOVE(&auxq, n, pfr_ktable, pfrkt_workq); SLIST_INSERT_HEAD(&addq, n, pfrkt_workq); + xadd++; } else if (!(flags & PFR_FLAG_DUMMY) && !(p->pfrkt_flags & PFR_TFLAG_ACTIVE)) { p->pfrkt_nflags = (p->pfrkt_flags & ~PFR_TFLAG_USRMASK) | key.pfrkt_flags; SLIST_INSERT_HEAD(&changeq, p, pfrkt_workq); } - xadd++; } if (!(flags & PFR_FLAG_DUMMY)) {