mirror of
https://github.com/tailscale/tailscale.git
synced 2025-08-12 05:37:32 +00:00
ipn/ipnlocal: close foreground sessions on SetServeConfig
This PR ensures zombie foregrounds are shutdown if a new ServeConfig is created that wipes the ongoing foreground ones. For example, "tailscale serve|funnel reset|off" should close all open sessions. Updates #8489 Signed-off-by: Marwan Sulaiman <marwan@tailscale.com>
This commit is contained in:

committed by
Marwan Sulaiman

parent
530aaa52f1
commit
651620623b
@@ -752,9 +752,9 @@ func TestWatchNotificationsCallbacks(t *testing.T) {
|
||||
}
|
||||
// Send a notification. Range over notifyWatchers to get the channel
|
||||
// because WatchNotifications doesn't expose the handle for it.
|
||||
for _, c := range b.notifyWatchers {
|
||||
for _, sess := range b.notifyWatchers {
|
||||
select {
|
||||
case c <- n:
|
||||
case sess.ch <- n:
|
||||
default:
|
||||
t.Fatalf("could not send notification")
|
||||
}
|
||||
|
Reference in New Issue
Block a user