Handle unknown enum defaults
This commit is contained in:
parent
596ec00943
commit
8dfd5f23c1
|
@ -48,6 +48,7 @@ extension NWTCPConnectionState: CustomStringConvertible {
|
|||
case .disconnected: return "disconnected"
|
||||
case .invalid: return "invalid"
|
||||
case .waiting: return "waiting"
|
||||
@unknown default: return "???"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -48,6 +48,7 @@ extension NWUDPSessionState: CustomStringConvertible {
|
|||
case .preparing: return "preparing"
|
||||
case .ready: return "ready"
|
||||
case .waiting: return "waiting"
|
||||
@unknown default: return "???"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -627,6 +627,9 @@ extension TunnelKitProvider {
|
|||
|
||||
case .LZO:
|
||||
return .lzo
|
||||
|
||||
default:
|
||||
break
|
||||
}
|
||||
} else if let se = error as? SessionError {
|
||||
switch se {
|
||||
|
|
|
@ -156,6 +156,7 @@ extension PacketCode: CustomStringConvertible {
|
|||
case .hardResetServerV2: return "HARD_RESET_SERVER_V2"
|
||||
case .dataV2: return "DATA_V2"
|
||||
case .unknown: return "UNKNOWN"
|
||||
@unknown default: return "UNKNOWN"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue