TunnelsManager: Don't lose .restarting state
Signed-off-by: Roopesh Chander <roop@roopc.net>
This commit is contained in:
parent
1f3ec042e0
commit
ecd66defe5
|
@ -336,10 +336,8 @@ class TunnelsManager {
|
|||
}
|
||||
}
|
||||
|
||||
if (tunnel.status == .restarting) && (session.status == .disconnected || session.status == .disconnecting) {
|
||||
if session.status == .disconnected {
|
||||
tunnel.startActivation(activationDelegate: self.activationDelegate)
|
||||
}
|
||||
if tunnel.status == .restarting && session.status == .disconnected {
|
||||
tunnel.startActivation(activationDelegate: self.activationDelegate)
|
||||
return
|
||||
}
|
||||
|
||||
|
@ -442,6 +440,9 @@ class TunnelContainer: NSObject {
|
|||
}
|
||||
|
||||
func refreshStatus() {
|
||||
if (status == .restarting) && (tunnelProvider.connection.status == .disconnected || tunnelProvider.connection.status == .disconnecting) {
|
||||
return
|
||||
}
|
||||
status = TunnelStatus(from: tunnelProvider.connection.status)
|
||||
isActivateOnDemandEnabled = tunnelProvider.isOnDemandEnabled
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue