summaryrefslogtreecommitdiffhomepage
path: root/device/mobilequirks.go
diff options
context:
space:
mode:
authorJason A. Donenfeld <Jason@zx2c4.com>2021-11-11 03:13:20 +0100
committerJason A. Donenfeld <Jason@zx2c4.com>2021-11-15 23:40:47 +0100
commit111e0566dce3fc3489cb75ee40b752b1b738e9c6 (patch)
tree0a107f1c0617ffb22f13f659e38b10645568b60b /device/mobilequirks.go
parente3134bf6659b13bbc4713fe2b9147463cc9ff374 (diff)
device: make new peers inherit broken mobile semantics
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Diffstat (limited to 'device/mobilequirks.go')
-rw-r--r--device/mobilequirks.go3
1 files changed, 3 insertions, 0 deletions
diff --git a/device/mobilequirks.go b/device/mobilequirks.go
index f27d9d7..680f5c7 100644
--- a/device/mobilequirks.go
+++ b/device/mobilequirks.go
@@ -5,7 +5,10 @@
package device
+// DisableSomeRoamingForBrokenMobileSemantics should ideally be called before peers are created,
+// though it will try to deal with it, and race maybe, if called after.
func (device *Device) DisableSomeRoamingForBrokenMobileSemantics() {
+ device.net.brokenRoaming = true
device.peers.RLock()
for _, peer := range device.peers.keyMap {
peer.Lock()