Skip to content
This repository was archived by the owner on May 14, 2024. It is now read-only.

Commit ce286f9

Browse files
committed
Merge pull request #92 from RevCBH/master
fix #76
2 parents 707d80d + e6dd5c0 commit ce286f9

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

SocketIO.m

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -138,8 +138,11 @@ - (void) connectToHost:(NSString *)host onPort:(NSInteger)port withParams:(NSDic
138138
cachePolicy:NSURLRequestReloadIgnoringLocalAndRemoteCacheData
139139
timeoutInterval:10.0];
140140

141-
_handshake = [NSURLConnection connectionWithRequest:request
142-
delegate:self];
141+
_handshake = [[NSURLConnection alloc] initWithRequest:request
142+
delegate:self startImmediately:NO];
143+
[_handshake scheduleInRunLoop:[NSRunLoop mainRunLoop]
144+
forMode:NSDefaultRunLoopMode];
145+
[_handshake start];
143146
if (_handshake) {
144147
_httpRequestData = [NSMutableData data];
145148
}

0 commit comments

Comments
 (0)