summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorAvery Pennarun <apenwarr@tailscale.com>2021-04-30 09:14:56 -0400
committerAvery Pennarun <apenwarr@tailscale.com>2021-04-30 09:17:47 -0400
commitac9cd48c80e5517bd90f26f7dfd0375f852e42ed (patch)
tree84780640038351e090c26ffb892c83e113b7ed78
parentecdba913d0b045e44a0d507e3cbc528d2d976a16 (diff)
downloadtailscale-ac9cd48c80e5517bd90f26f7dfd0375f852e42ed.tar.xz
tailscale-ac9cd48c80e5517bd90f26f7dfd0375f852e42ed.zip
ipnlocal: fix deadlock when calling Shutdown() from Start().
Signed-off-by: Avery Pennarun <apenwarr@tailscale.com>
-rw-r--r--ipn/ipnlocal/local.go2
1 files changed, 2 insertions, 0 deletions
diff --git a/ipn/ipnlocal/local.go b/ipn/ipnlocal/local.go
index e2b6cb22b..773e09043 100644
--- a/ipn/ipnlocal/local.go
+++ b/ipn/ipnlocal/local.go
@@ -682,7 +682,9 @@ func (b *LocalBackend) Start(opts ipn.Options) error {
// into sync with the minimal changes. But that's not how it
// is right now, which is a sign that the code is still too
// complicated.
+ b.mu.Unlock()
b.cc.Shutdown()
+ b.mu.Lock()
}
httpTestClient := b.httpTestClient