mirror of
https://github.com/leonboe1/QuickDrop.git
synced 2026-11-21 13:55:58 +00:00
Ignore keepalive during handshake
This commit is contained in:
1 parent
50d4d4ee92
commit
04e056da02
1 file changed
+10
@@ -76,6 +76,16 @@ class InboundNearbyConnection: NearbyConnection {
|
|||||||
if currentState != .receivingFiles {
|
if currentState != .receivingFiles {
|
||||||
log("[InboundNearbyConnection \(self.id)] Received frame in state \(currentState)...")
|
log("[InboundNearbyConnection \(self.id)] Received frame in state \(currentState)...")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if !encryptionDone,
|
||||||
|
currentState != .initial,
|
||||||
|
let frame = try? Location_Nearby_Connections_OfflineFrame(serializedBytes: frameData),
|
||||||
|
frame.hasV1,
|
||||||
|
frame.v1.hasType,
|
||||||
|
case .keepAlive = frame.v1.type {
|
||||||
|
log("[InboundNearbyConnection \(self.id)] Ignoring keep-alive during handshake in state \(currentState)")
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
do {
|
do {
|
||||||
switch currentState {
|
switch currentState {
|
||||||
|
|||||||
Reference in new issue
Block a user