aboutsummaryrefslogtreecommitdiffstats
path: root/sys/openbsd/dev_pf.txt
diff options
context:
space:
mode:
authorDmitry Vyukov <dvyukov@google.com>2020-08-04 12:29:59 +0200
committerDmitry Vyukov <dvyukov@google.com>2020-08-04 16:53:16 +0200
commit5ed76afa814812edaeaff2ea7b3227c18d5de5a6 (patch)
tree9074ce6cb6d39bd008c841c574b8621581904972 /sys/openbsd/dev_pf.txt
parent80a0690249dc4dbbbed95ba197192b99c73694c5 (diff)
pkg/compiler: check for unused resources
If a resource is never used as an input, it is not useful. It's effectively the same as using an integer. Detect such cases, they are quite confusing. Fix all existing errors in descriptions. This uncovered some interesting bugs as well, e.g. use of a completely unrelated fd subtype after copy-paste (while the resource that was supposed to be used there is completely unused).
Diffstat (limited to 'sys/openbsd/dev_pf.txt')
-rw-r--r--sys/openbsd/dev_pf.txt7
1 files changed, 2 insertions, 5 deletions
diff --git a/sys/openbsd/dev_pf.txt b/sys/openbsd/dev_pf.txt
index 93ce99b06..c07e9d95d 100644
--- a/sys/openbsd/dev_pf.txt
+++ b/sys/openbsd/dev_pf.txt
@@ -10,9 +10,6 @@ include <net/if.h>
include <net/pfvar.h>
# The following ioctl commands are restricted in neutralize(), see init.go.
-_ = DIOCCLRSTATES
-_ = DIOCKILLSTATES
+_ = DIOCCLRSTATES, DIOCKILLSTATES
-resource fd_pf[fd]
-
-openat$pf(fd const[AT_FDCWD], file ptr[in, string["/dev/pf"]], flags flags[open_flags], mode const[0]) fd_pf
+openat$pf(fd const[AT_FDCWD], file ptr[in, string["/dev/pf"]], flags flags[open_flags], mode const[0]) fd