1
0
mirror of https://git.zx2c4.com/wireguard-go synced 2024-11-15 01:05:15 +01:00

device: align 64-bit atomic member in Device

Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
This commit is contained in:
Jason A. Donenfeld 2021-11-16 21:07:15 +01:00
parent 9d699ba730
commit fc4f975a4d

View File

@ -53,16 +53,17 @@ type Device struct {
publicKey NoisePublicKey publicKey NoisePublicKey
} }
rate struct {
underLoadUntil int64
limiter ratelimiter.Ratelimiter
}
peers struct { peers struct {
sync.RWMutex // protects keyMap sync.RWMutex // protects keyMap
keyMap map[NoisePublicKey]*Peer keyMap map[NoisePublicKey]*Peer
} }
// Keep this 8-byte aligned
rate struct {
underLoadUntil int64
limiter ratelimiter.Ratelimiter
}
allowedips AllowedIPs allowedips AllowedIPs
indexTable IndexTable indexTable IndexTable
cookieChecker CookieChecker cookieChecker CookieChecker