make attaching to stopped processes work under windows

Eli Zaretskii eliz@gnu.org
Mon Mar 2 21:21:00 GMT 2009


> Date: Mon, 2 Mar 2009 20:56:25 +0100
> From: Oswald Buddenhagen <oswald.buddenhagen@trolltech.de>
> 
> > As someone who have certainly read the patch, I can assure you that
> > Chris's question didn't sound like it was answered in the comment.
> >
> well, then i would be thankful for questions that somehow indicate what
> is missing from the comment or why it is entirely irrelevant.

It is not irrelevant, but its wording is obscure and unclear, at least
to me.  The full comment reads:

  +      /* Resume main thread if we are attaching to a suspended
  +	 process.
  +	 Note that we are not trying to handle multi-threaded
  +	 situations, as these are likely to be too complex anyway.
  +	 This is primarily meant to cover the case where someone
  +	 creates a process in suspended state and hands it over
  +	 to gdb (this is an abstraction - you cannot actually do
  +	 that due to Windows bugs. You need to start debugging the
  +	 process yourself, and once it has started up, you suspend
  +	 it and detach from it). */

Perhaps I read this too naively, but note how you first seem to
describe a use-case:

    This is primarily meant to cover the case where someone
    creates a process in suspended state and hands it over
    to gdb

but then immediately say that it cannot be done:

    this is an abstraction - you cannot actually do
    that due to Windows bugs.

After reading this, I already become confused.

    You need to start debugging the process yourself,
    and once it has started up, you suspend it and detach from it

And now I'm _really_ confused: ``detach''? didn't you say ``attach''
above? why detach from a process if you want to debug it?

Of course, Chris knows much more than I do about debugging on Windows,
so perhaps his difficulty with your concept was different and more
deep.  I will let him speak for himself.

> i made an assertion and expect it to be discussed, not ignored.

When your assertions are not clearly worded, it is customary to ask
questions.  Asking questions is not ignoring; quite the opposite: it
means your work is of interest and of importance.

> what cgf did left me with a blank stare and i find *that* rude
> towards me.

I find nothing rude in Chris's question.



More information about the Gdb-patches mailing list