fix quicClient
This commit is contained in:
parent
3c42aa58f3
commit
26dc6b5152
@ -66,9 +66,6 @@ actor SDLQUICClient {
|
|||||||
public var eventStream: AsyncStream<SDLQUICEvent>
|
public var eventStream: AsyncStream<SDLQUICEvent>
|
||||||
private let eventCont: AsyncStream<SDLQUICEvent>.Continuation
|
private let eventCont: AsyncStream<SDLQUICEvent>.Continuation
|
||||||
|
|
||||||
private var readTask: Task<Void, Never>?
|
|
||||||
private var pingTask: Task<Void, Never>?
|
|
||||||
|
|
||||||
private let connection: NWConnection
|
private let connection: NWConnection
|
||||||
private let queue = DispatchQueue(label: "com.sdl.QUICClient.queue") // 专用队列保证线程安全
|
private let queue = DispatchQueue(label: "com.sdl.QUICClient.queue") // 专用队列保证线程安全
|
||||||
|
|
||||||
@ -195,8 +192,6 @@ actor SDLQUICClient {
|
|||||||
}
|
}
|
||||||
|
|
||||||
deinit {
|
deinit {
|
||||||
self.readTask?.cancel()
|
|
||||||
self.pingTask?.cancel()
|
|
||||||
self.messageCont.finish()
|
self.messageCont.finish()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user