aboutsummaryrefslogtreecommitdiffstats
path: root/replay
diff options
context:
space:
mode:
authorJason A. Donenfeld <Jason@zx2c4.com>2020-09-07 18:51:49 +0200
committerJason A. Donenfeld <Jason@zx2c4.com>2020-09-07 18:51:49 +0200
commit0cfa3314ee2740cd94cf7064cc79fdea7b1e0dde (patch)
treef225f3d30cd2e9dce8ed0fe08f031a3c6a7660a4 /replay
parentdevice: get free port when testing (diff)
downloadwireguard-go-0cfa3314ee2740cd94cf7064cc79fdea7b1e0dde.tar.xz
wireguard-go-0cfa3314ee2740cd94cf7064cc79fdea7b1e0dde.zip
replay: divide by bits-per-byte
Bits / Bytes-per-Word misses the step of also dividing by Bits-per-Byte, which we need in order for this to make sense. Reported-by: Riobard Zhan <me@riobard.com> Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Diffstat (limited to 'replay')
-rw-r--r--replay/replay.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/replay/replay.go b/replay/replay.go
index e5c7391..85647f5 100644
--- a/replay/replay.go
+++ b/replay/replay.go
@@ -26,7 +26,7 @@ const (
)
const (
- BacktrackWords = CounterBitsTotal / _WordSize
+ BacktrackWords = CounterBitsTotal / 8 / _WordSize
)
func minUint64(a uint64, b uint64) uint64 {