strace: infinite exception c0000005 loop on segmentation fault

Jon Turney jon.turney@dronecode.org.uk
Sat May 17 14:01:58 GMT 2025


On 16/05/2025 22:37, Jon Turney via Cygwin wrote:
> On 16/05/2025 16:43, Takashi Yano wrote:
>> Hi Jon,
> [...]
>>>>>> I could reproduce that. And also found cygwin 3.4.10 does not have this
>>> issue. I'll look into this.
>>>> I could bisect the issue and found the next commit triggered the issue.
>>>> commit 91457377d6c9f89a08b1b70e45cbae87ef467119
>> Author: Jon Turney <jon.turney@dronecode.org.uk>
>> Date:   Thu Jan 11 20:00:14 2024 +0000
>>> [...]
>> Thanks for looking into this.
>>> I also found the following patch fixes the issue. I'm not sure
>> this is the right thing, so could you please have a look?
>>>> diff --git a/winsup/cygwin/exceptions.cc b/winsup/cygwin/exceptions.cc
>> index 9763a1b04..aea2821f6 100644
>> --- a/winsup/cygwin/exceptions.cc
>> +++ b/winsup/cygwin/exceptions.cc
>> @@ -597,7 +597,7 @@ try_to_debug ()
>>       {
>>         extern void break_here ();
>>         break_here ();
>> -      return 1;
>> +      return 0;
>>       }
>>     /* Otherwise, invoke the JIT debugger, if set */
>> Hmm... at this remove in time, I'm not sure why I made that change.
>> Well, "consistently return non-zero from try_to_debug() if we debugged", 
> but maybe that misunderstands the meaning of the return value...

See yeah, it seems I came to understand that a bit better at:
https://cygwin.com/pipermail/cygwin-patches/2024q1/012605.html
but never got back to this piece of code.


More information about the Cygwin mailing list

AltStyle によって変換されたページ (->オリジナル) /