mirror of
https://github.com/leonboe1/QuickDrop.git
synced 2026-11-11 02:51:11 +00:00
Fix too short timeout interval
This commit is contained in:
1 parent
b68e4a7345
commit
5ecc66d57b
2 files changed
+7
-3
No files matched your search
@@ -30,7 +30,7 @@ class NearbyConnection {
|
||||
private var connectionClosed: Bool = false
|
||||
|
||||
private var inactivityTimer: DispatchSourceTimer?
|
||||
private let timeoutInterval: TimeInterval = 7
|
||||
private let timeoutInterval: TimeInterval = 100 // seconds
|
||||
|
||||
// UKEY2-related state
|
||||
var publicKey: ECPublicKey?
|
||||
@@ -253,10 +253,14 @@ class NearbyConnection {
|
||||
}
|
||||
|
||||
func sendTransferSetupFrame(_ frame: Sharing_Nearby_Frame) throws {
|
||||
log("Sending transfer setup frame.")
|
||||
try sendBytesPayload(data: frame.serializedData(), id: Int64.random(in: Int64.min ... Int64.max))
|
||||
}
|
||||
|
||||
func sendBytesPayload(data: Data, id: Int64) throws {
|
||||
|
||||
log("Sending bytes payload with ID \(id) of length \(data.count)")
|
||||
|
||||
var transfer = Location_Nearby_Connections_PayloadTransferFrame()
|
||||
transfer.packetType = .data
|
||||
transfer.payloadChunk.offset = 0
|
||||
|
||||
@@ -915,7 +915,7 @@
|
||||
MTL_FAST_MATH = YES;
|
||||
ONLY_ACTIVE_ARCH = YES;
|
||||
SDKROOT = macosx;
|
||||
SHARED_BUILD = 51;
|
||||
SHARED_BUILD = 52;
|
||||
SHARED_VERSION = 1.10.3;
|
||||
SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG;
|
||||
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
|
||||
@@ -974,7 +974,7 @@
|
||||
MTL_ENABLE_DEBUG_INFO = NO;
|
||||
MTL_FAST_MATH = YES;
|
||||
SDKROOT = macosx;
|
||||
SHARED_BUILD = 51;
|
||||
SHARED_BUILD = 52;
|
||||
SHARED_VERSION = 1.10.3;
|
||||
SWIFT_COMPILATION_MODE = wholemodule;
|
||||
SWIFT_OPTIMIZATION_LEVEL = "-O";
|
||||
|
||||
Reference in new issue
Block a user