8000
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e1d0a98 commit 13f68f1Copy full SHA for 13f68f1
ios/Classes/Broadcast/FlutterSocketConnection.m
@@ -81,12 +81,16 @@ - (void)openWithStreamDelegate:(id <NSStreamDelegate>)streamDelegate {
81
dispatch_resume(listeningSource);
82
}
83
84
-- (void)close {
85
- [self performSelector:@selector(unscheduleStreams) onThread:self.networkThread withObject:nil waitUntilDone:true];
+- (void)close {
+ if (![self.networkThread isExecuting]){
86
+ return;
87
+ }
88
89
+ [self performSelector:@selector(unscheduleStreams) onThread:self.networkThread withObject:nil waitUntilDone:true];
90
+
91
self.inputStream.delegate = nil;
92
self.outputStream.delegate = nil;
-
93
94
[self.inputStream close];
95
[self.outputStream close];
96
0 commit comments