On Thu, Oct 31, 2019 at 05:51:38PM +0100, Tobias Burnus wrote: > On 10/31/19 5:42 PM, Steve Kargl wrote: > > I suspect the other BSDs also follow posix. I wonder if gfortran > > should either apply a mask to the stop code or simply map nonzero > > values to one of EXIT_FAILURE, SIGQUIT, or SIGABRT. Perhaps, > > > > - exit (code); > > + exit (EXIT_FAILURE); > > > Or "exit (code > 255 ? EXIT_FAILURE : code);". I think EXIT_FAILURE is 1 > on most systems. I recall that windows interpreted exit(3) as abort, > which can also be surprising. (But is fine for our testsuite purpose.)
As I replied to Jakub, I'm fine with the ternary expression. I did a brief scan of signal.h, and there is a SIGSTOP. Depending on whether a user installed a signal handler, SIGSTOP might lead to a zombie process so I did not mention it as a possibility. -- Steve