This is the mail archive of the
mailing list for the Cygwin project.
Re: Bug: Synchronous signals broken on Cygwin 64
On 2018-04-26 12:45, Houder wrote:
On Thu, 26 Apr 2018 09:57:59, Thomas Zimmermann wrote:
Hello mailing list,
I noticed that synchronous signals (e.g., SIGSEGV, SIGFPE) appear to
broken on 64-bit Cygwin systems. I could not find additional
on the mailing list. If this is not already a known problem, you'll
some analysis below.
I use Cygwin DLL 2.10 with all packages up-to-date. My test system
The expected behavior is that an installed signal handler runs exactly
once for a signal and the OS terminates the program if the handler
returns. This works on 32-bit Cygwin. From my observation, Cygwin 64
differs in the follow ways:
.. uhm, unless SA_RESETHAND (sa_flags) has been specified, I expect the
handler to be invoked again and again ...
... and if SA_RESETHAND has been specified, the OS will terminate
program after the 1st invocation of the handler (yes, in case of
type of exception; in this case FPE)
And that is what I observe on Linux ...
1) Generating a synchronous signal on the main thread, makes the
handler enter an endless loop. The attached test 'syncsig.c'
2) Generating a synchronous signal on an additional POSIX thread
the installed signal handler entirely. The handler does not run and
program gets terminated immediately. The attached test 'syncsig_mt.c'
Yes, this behaviour is wrong ...
Problem reports: http://cygwin.com/problems.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple