[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Mysterious crash in NSRunLoop, using libobjc2 on Linux

From: David Chisnall
Subject: Re: Mysterious crash in NSRunLoop, using libobjc2 on Linux
Date: Thu, 7 Dec 2017 20:22:19 +0000

On 7 Dec 2017, at 19:54, Lobron, David <address@hidden> wrote:
> I did this, and I've pasted the output below.  At first glance, the 
> exceptions all seem to be the same (or at least, all have the same address of 
> 0x17158c80).  I'm not entirely sure how to interpret the rest of the action 
> there.  One thing that leaps out is that there seem to be personalities 
> involved: GNUCOBJC and GNUCC++.  The code that throws this exception is a .mm 
> file, i.e., Objective-C++, with a mix of ObjC and C++.  

Aha!  That might be it, and might be enough to come up with a reduced test 
case.  When you throw the exception, it’s an ObjC exception.  When you throw it 
through an ObjC++ stack frame, it’s transformed into a C++ exception and passed 
to the C++ personality function, but only when the cleanup is run for that 
frame.  I suspect that the ObjC personality function is not correctly handling 
the transformation back to an ObjC exception for the catch.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]