Re: DOS/Windows-specific code: maint.c

Eli Zaretskii
2001-05-10T08:53:00Z

On Wed, 9 May 2001, Andrew Cagney wrote:

> > #ifdef __DJGPP__
> > /* SIGQUIT by default is ignored, so use SIGABRT instead. */
> > signal (SIGABRT, SIG_DFL);
> > kill (getpid (), SIGABRT);
> > #else
> > signal (SIGQUIT, SIG_DFL);
> > kill (getpid (), SIGQUIT);
> > #endif
> > }
> > }
> > #endif
>
> I think this is a bug in DJGPP :-)

No, it's a feature ;-) DOS/Windows users do not expect a ^\ to abort
their program, so by default SIGQUIT is ignored.

If you want to stay with SIGQUIT, I can do something in go32-nat.c to get
the standard Unix behavior. However, note that there's also the _WIN32
condition which ifdefs away the whole function.

> The other option is to just call abort() is that always guarenteed to
> dump core?

That's what I thought; abort() sounds like a more portable way of dumping
core where core files are supported and doing something similar where
they aren't.