Re: How to connect to children process
- From: "Oleg Starodumov" <com-dot-debuginfo-at-oleg>
- Date: Tue, 6 Feb 2007 11:38:09 +0200
So you want to communicate with the debugger from the debuggee?
AFAIK there is no direct API for that even in WinDbg, but the communication
can be achieved via OutputDebugString or special exceptions.
In case of OutputDebugString, you use it to pass commands from the debuggee
to the debugger (WinDbg), the commands are preceded by a special prefix,
and the debugger should be made aware of this prefix via .ocommand command.
In case of exceptions, the debuggee raises an application-specific exception
(usually within __try..__except so that it's handled), and the debugger is configured
with sx* command to run a set of user-defined commands when this exception is raised.
I haven't had to use kernel debugger for a long time, so I don't know
if these approaches can work there (OutputDebugString probably does not,
but exception-based approach should probably work).
Oleg
"Metek" <Metek@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message news:D5C71AB9-BDC7-4F24-9E2C-26DCC16D412A@xxxxxxxxxxxxxxxx
Oleg,
Local debug is not always suitable. Therefore we would like to find more
general solution.
Other manual operations are:
(a) Re-starting of process A under WinDbg
(b) Reload symbols at first break (.reload /user)
(c) Restoring of break points (or embedding of DebugBreak(s))
Al
"Oleg Starodumov" wrote:
The problem of locked pdb should not exist in the local scenario
(when debugging the parent process (A) and its children with WinDbg
on the local machine).
What other manual operations are needed at this time (in local scenario)?
(other than recompiling the dll and (optionally) copying the new version
over the old one?)
Oleg
Oleg,
Main problem is amount of manual operations required per debug cycle.
Locking of symbols is only part of this problem.
When I recompile, linker complains that .PDB file cannot be written. For
solve this, I break to WinDbg and invoke .reload /user. After it linker works.
But as I said - loking is only part of the problem. Another part is that
connection to DLL with debugger takes sensible amount of time and manual
operations.
Therefore I'm looking for a method to automate entire procedure.
With best regards,
Al
.
- Follow-Ups:
- Re: How to connect to children process
- From: Metek
- Re: How to connect to children process
- References:
- Re: How to connect to children process
- From: Oleg Starodumov
- Re: How to connect to children process
- From: Metek
- Re: How to connect to children process
- From: Oleg Starodumov
- Re: How to connect to children process
- From: Metek
- Re: How to connect to children process
- From: Oleg Starodumov
- Re: How to connect to children process
- From: Metek
- Re: How to connect to children process
- From: Oleg Starodumov
- Re: How to connect to children process
- From: Metek
- Re: How to connect to children process
- Prev by Date: RE: Code coverage for ie hosted user controls
- Next by Date: switching between debugged processes in vs2003
- Previous by thread: Re: How to connect to children process
- Next by thread: Re: How to connect to children process
- Index(es):
Relevant Pages
|
Loading