Hi everyone, I have a cinterop with <libPusher> th...
# kotlin-native
o
Hi everyone, I have a cinterop with libPusher that was working fine in 1.3.72, now in 1.4.10 I'm getting a
SIGABRT
in
objc_loadWeakRetained ()
. This is the stacktrace
Copy code
#0	0x00007fff5225a33a in __pthread_kill ()
#1	0x00007fff52304e60 in pthread_kill ()
#2	0x00007fff521e9b7c in abort ()
#3	0x000000010571ada9 in konan::abort() ()
#4	0x000000010573566e in TerminateWithUnhandledException ()
#5	0x00000001057355ba in KonanTerminateHandler() ()
#6	0x00007fff500eec87 in std::__terminate(void (*)()) ()
#7	0x00007fff500eec29 in std::terminate() ()
#8	0x000000010571c571 in (anonymous namespace)::_tryRetainImp(objc_object*, objc_selector*) ()
#9	0x00007fff512b88ce in objc_loadWeakRetained ()
#10	0x0000000104583cf6 in -[PTPusher channelAuthorizationDelegate] at {path}/Pods/libPusher/Library/PTPusher.h:139
#11	0x0000000104582934 in -[PTPusher subscribeToChannel:] at {path}/Pods/libPusher/Library/PTPusher.m:287
#12	0x0000000104582d37 in -[PTPusher subscribeAll] at {path}/Pods/libPusher/Library/PTPusher.m:314
#13	0x0000000104583278 in -[PTPusher pusherConnectionDidConnect:] at {path}/Pods/libPusher/Library/PTPusher.m:374
#14	0x000000010458801f in -[PTPusherConnection webSocket:didReceiveMessage:] at {path}/Pods/libPusher/Library/PTPusherConnection.m:155
#15	0x00000001047c0533 in __30-[SRWebSocket _handleMessage:]_block_invoke at {path}/Pods/SocketRocket/SocketRocket/SRWebSocket.m:836
#16	0x000000010ace3f11 in _dispatch_call_block_and_release ()
#17	0x000000010ace4e8e in _dispatch_client_callout ()
#18	0x000000010acf2d97 in _dispatch_main_queue_callback_4CF ()
#19	0x00007fff23da1869 in __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ ()
#20	0x00007fff23d9c3b9 in __CFRunLoopRun ()
#21	0x00007fff23d9b8a4 in CFRunLoopRunSpecific ()
#22	0x00007fff38c05bbe in GSEventRunModal ()
#23	0x00007fff49372964 in UIApplicationMain ()
It's also happening in
1.4.0
and
1.4.20-M1
s
This behaviour is expected. You have a non-shared object that is loaded from weak reference on other thread. This case is not supported since 1.4.0 and will remain so for some time. The exception message should contain some details on the object. Please check the output. To fix the problem it should be enough to freeze the object. Is freezing possible in your case? Does it fix the problem?
o
Hi, thanks for the response, trying freezing now
Yes, it worked, you're right about the message, I'm used to spot these issues with the usual
InvalidMutabilityException
or
IncorrectDereferenceException
👍 1