Skip to content

Crash in FoundationStream.write(data:), similar to https://github.com/socketio/socket.io-client-swift/issues/1118 #1250

Closed
@TarasGordienko

Description

@TarasGordienko

Crash happens rarely in crashlytics. Seems to be similar to #1118, however empty closure exists only in 2 places in code and replacing it with nil does not solve the issue (

postWait.append((String(SocketEnginePacketType.close.rawValue), {}))
, )

Crashed: NSOperationQueue 0x11dbe7160 (QOS: UNSPECIFIED)
0 libobjc.A.dylib 0x184458050 objc_msgSend + 16
1 Starscream 0x1018a1d0c FoundationStream.write(data:) + 241 (WebSocket.swift:241)
2 Starscream 0x1018a2bac protocol witness for WSStream.write(data:) in conformance FoundationStream ()
3 Starscream 0x1018a9bd8 closure #1 in WebSocket.dequeueWrite(_:code:writeCompletion:) + 1268 (WebSocket.swift:1268)
4 Starscream 0x1018a0400 thunk for @escaping @callee_guaranteed () -> () ()
5 Foundation 0x184b11c60 NSBLOCKOPERATION_IS_CALLING_OUT_TO_A_BLOCK + 24
6 Foundation 0x184a137e8 -[NSBlockOperation main] + 104
7 Foundation 0x184b13fbc NSOPERATION_IS_INVOKING_MAIN + 24
8 Foundation 0x184a13464 -[NSOperation start] + 740
9 Foundation 0x184b149e8 NSOPERATIONQUEUE_IS_STARTING_AN_OPERATION + 24
10 Foundation 0x184b144a8 __NSOQSchedule_f + 184
11 libdispatch.dylib 0x1843f53ac _dispatch_block_async_invoke2 + 144
12 libdispatch.dylib 0x1843e900c _dispatch_client_callout + 20
13 libdispatch.dylib 0x1843eb78c _dispatch_continuation_pop + 408
14 libdispatch.dylib 0x1843eaeec _dispatch_async_redirect_invoke + 596
15 libdispatch.dylib 0x1843f7bd4 _dispatch_root_queue_drain + 348
16 libdispatch.dylib 0x1843f8384 _dispatch_worker_thread2 + 120
17 libsystem_pthread.dylib 0x18444ea60 _pthread_wqthread + 216
18 libsystem_pthread.dylib 0x184454c78 start_wqthread + 8

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions