aboutsummaryrefslogtreecommitdiffstats
path: root/device/mobilequirks.go
diff options
context:
space:
mode:
authorJason A. Donenfeld <Jason@zx2c4.com>2021-04-12 16:19:35 -0600
committerJason A. Donenfeld <Jason@zx2c4.com>2021-04-12 16:19:35 -0600
commitc7cd2c9eab6af6c676bcf286af37d729438fceae (patch)
treebd68849ae92e692d56f06f7040a77d5f199473b1 /device/mobilequirks.go
parentconn: reconstruct v4 vs v6 receive function based on symtab (diff)
downloadwireguard-go-c7cd2c9eab6af6c676bcf286af37d729438fceae.tar.xz
wireguard-go-c7cd2c9eab6af6c676bcf286af37d729438fceae.zip
device: don't defer unlocking from loop
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Diffstat (limited to '')
-rw-r--r--device/mobilequirks.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/device/mobilequirks.go b/device/mobilequirks.go
index a31ce3a..f27d9d7 100644
--- a/device/mobilequirks.go
+++ b/device/mobilequirks.go
@@ -9,8 +9,8 @@ func (device *Device) DisableSomeRoamingForBrokenMobileSemantics() {
device.peers.RLock()
for _, peer := range device.peers.keyMap {
peer.Lock()
- defer peer.Unlock()
peer.disableRoaming = peer.endpoint != nil
+ peer.Unlock()
}
device.peers.RUnlock()
}