Combine double log invocations
This commit is contained in:
parent
2cfba533a5
commit
d0cc2a8afd
|
@ -395,8 +395,7 @@ class TunnelContainer: NSObject {
|
||||||
activationDelegate?.tunnelActivationAttemptFailed(tunnel: self, error: .failedWhileSaving(systemError: error!))
|
activationDelegate?.tunnelActivationAttemptFailed(tunnel: self, error: .failedWhileSaving(systemError: error!))
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
wg_log(.debug, staticMessage: "startActivation: Tunnel saved after re-enabling")
|
wg_log(.debug, staticMessage: "startActivation: Tunnel saved after re-enabling, invoking startActivation")
|
||||||
wg_log(.debug, staticMessage: "startActivation: Invoking startActivation")
|
|
||||||
self.startActivation(recursionCount: recursionCount + 1, lastError: NEVPNError(NEVPNError.configurationUnknown), activationDelegate: activationDelegate)
|
self.startActivation(recursionCount: recursionCount + 1, lastError: NEVPNError(NEVPNError.configurationUnknown), activationDelegate: activationDelegate)
|
||||||
}
|
}
|
||||||
return
|
return
|
||||||
|
@ -434,8 +433,7 @@ class TunnelContainer: NSObject {
|
||||||
activationDelegate?.tunnelActivationAttemptFailed(tunnel: self, error: .failedWhileLoading(systemError: systemError))
|
activationDelegate?.tunnelActivationAttemptFailed(tunnel: self, error: .failedWhileLoading(systemError: systemError))
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
wg_log(.debug, staticMessage: "startActivation: Tunnel reloaded")
|
wg_log(.debug, staticMessage: "startActivation: Tunnel reloaded, invoking startActivation")
|
||||||
wg_log(.debug, staticMessage: "startActivation: Invoking startActivation")
|
|
||||||
self.startActivation(recursionCount: recursionCount + 1, lastError: systemError, activationDelegate: activationDelegate)
|
self.startActivation(recursionCount: recursionCount + 1, lastError: systemError, activationDelegate: activationDelegate)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -66,7 +66,7 @@ class PacketTunnelProvider: NEPacketTunnelProvider {
|
||||||
|
|
||||||
let handle = wireguardSettings.withGoString { return wgTurnOn($0, fileDescriptor) }
|
let handle = wireguardSettings.withGoString { return wgTurnOn($0, fileDescriptor) }
|
||||||
if handle < 0 {
|
if handle < 0 {
|
||||||
wg_log(.error, staticMessage: "Starting tunnel failed: Could not start WireGuard")
|
wg_log(.error, message: "Starting tunnel failed with wgTurnOn returning \(handle)")
|
||||||
errorNotifier.notify(PacketTunnelProviderError.couldNotStartWireGuard)
|
errorNotifier.notify(PacketTunnelProviderError.couldNotStartWireGuard)
|
||||||
startTunnelCompletionHandler(PacketTunnelProviderError.couldNotStartWireGuard)
|
startTunnelCompletionHandler(PacketTunnelProviderError.couldNotStartWireGuard)
|
||||||
return
|
return
|
||||||
|
@ -76,8 +76,7 @@ class PacketTunnelProvider: NEPacketTunnelProvider {
|
||||||
let networkSettings: NEPacketTunnelNetworkSettings = packetTunnelSettingsGenerator!.generateNetworkSettings()
|
let networkSettings: NEPacketTunnelNetworkSettings = packetTunnelSettingsGenerator!.generateNetworkSettings()
|
||||||
setTunnelNetworkSettings(networkSettings) { error in
|
setTunnelNetworkSettings(networkSettings) { error in
|
||||||
if let error = error {
|
if let error = error {
|
||||||
wg_log(.error, staticMessage: "Starting tunnel failed: Error setting network settings.")
|
wg_log(.error, message: "Starting tunnel failed with setTunnelNetworkSettings returning \(error.localizedDescription)")
|
||||||
wg_log(.error, message: "Error from setTunnelNetworkSettings: \(error.localizedDescription)")
|
|
||||||
errorNotifier.notify(PacketTunnelProviderError.coultNotSetNetworkSettings)
|
errorNotifier.notify(PacketTunnelProviderError.coultNotSetNetworkSettings)
|
||||||
startTunnelCompletionHandler(PacketTunnelProviderError.coultNotSetNetworkSettings)
|
startTunnelCompletionHandler(PacketTunnelProviderError.coultNotSetNetworkSettings)
|
||||||
} else {
|
} else {
|
||||||
|
|
Loading…
Reference in New Issue