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