This is the mail archive of the gdb@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

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



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.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]