File tree 2 files changed +5
-0
lines changed
ios/PacketTunnelCore/TunnelMonitor
2 files changed +5
-0
lines changed Original file line number Diff line number Diff line change @@ -203,6 +203,7 @@ public final class TunnelMonitor: TunnelMonitorProtocol {
203
203
logger. debug ( " checkConnectivity timeout: \( timeout) " )
204
204
205
205
let evaluation = state. evaluateConnection ( now: now, pingTimeout: timeout)
206
+ logger. debug ( " checkConnectivity evalutation: \( evaluation) " )
206
207
207
208
if evaluation != . ok {
208
209
logger. trace ( " Evaluation: \( evaluation) " )
Original file line number Diff line number Diff line change 8
8
9
9
import Foundation
10
10
import MullvadTypes
11
+ import MullvadLogging
11
12
12
13
/// Connection state.
13
14
enum TunnelMonitorConnectionState {
@@ -73,6 +74,8 @@ struct TunnelMonitorState {
73
74
// Timings and timeouts.
74
75
let timings : TunnelMonitorTimings
75
76
77
+ let logger = Logger ( label: " TunnelMonitorState " )
78
+
76
79
func evaluateConnection( now: Date , pingTimeout: Duration ) -> ConnectionEvaluation {
77
80
switch connectionState {
78
81
case . connecting:
@@ -87,6 +90,7 @@ struct TunnelMonitorState {
87
90
func getPingTimeout( ) -> Duration {
88
91
switch connectionState {
89
92
case . connecting:
93
+ logger. debug ( " getPingTimeout: \( retryAttempt) " )
90
94
let multiplier = timings. establishTimeoutMultiplier. saturatingPow ( retryAttempt)
91
95
let nextTimeout = timings. initialEstablishTimeout * Double( multiplier)
92
96
You can’t perform that action at this time.
0 commit comments