Release 2.6.2: disconnect AWG without freezing the UI.
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -120,15 +120,16 @@ func (e *Engine) stopLocked() error {
|
||||
if !e.running {
|
||||
return nil
|
||||
}
|
||||
if e.proxies != nil {
|
||||
_ = e.proxies.Close()
|
||||
e.proxies = nil
|
||||
}
|
||||
// Close device first so tun/netstack dials fail and relays exit promptly.
|
||||
if e.dev != nil {
|
||||
e.dev.Close()
|
||||
e.dev = nil
|
||||
}
|
||||
e.tnet = nil
|
||||
if e.proxies != nil {
|
||||
_ = e.proxies.Close()
|
||||
e.proxies = nil
|
||||
}
|
||||
e.running = false
|
||||
return nil
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user