aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/service/firewall/rules.go
diff options
context:
space:
mode:
authorJason A. Donenfeld <Jason@zx2c4.com>2019-05-13 14:47:47 +0200
committerJason A. Donenfeld <Jason@zx2c4.com>2019-05-13 14:47:47 +0200
commit6f384b5b57fe336480013ec04918f3b695e53222 (patch)
treef17b08d18276b5051cb2c8d13796a1698be1b2e8 /service/firewall/rules.go
parentversion: bump (diff)
downloadwireguard-windows-6f384b5b57fe336480013ec04918f3b695e53222.tar.xz
wireguard-windows-6f384b5b57fe336480013ec04918f3b695e53222.zip
firewall: fix logic error
Diffstat (limited to '')
-rw-r--r--service/firewall/rules.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/service/firewall/rules.go b/service/firewall/rules.go
index bab3ed2b..364c7d1d 100644
--- a/service/firewall/rules.go
+++ b/service/firewall/rules.go
@@ -990,7 +990,7 @@ func blockAll(session uintptr, baseObjects *baseObjects, weight uint8) error {
// Block all DNS traffic except towards specified DNS servers.
func blockDns(except []net.IP, session uintptr, baseObjects *baseObjects, weightAllow uint8, weightDeny uint8) error {
- if weightDeny <= weightAllow {
+ if weightDeny >= weightAllow {
return errors.New("The allow weight must be greater than the deny weight")
}