Visual C++ 2008 has a great tool called "Attach to Process", which start watching a specific process for debugging symbols and handles correctly your breakpoints. This is fantastic, but I would like some more.
I would like to attach my debugging session to a executable file, such that when it is executed, debugger takes command. So I would, say, attach my debugging session to d:\listener\solver.exe
, and start an app that eventually will call this executable, and then Visual C++ would pop on the screen when it reached a breakpoint.
Is that possible? How do I do that?
There is a build in feature in windows that enables you to start a process with a debugger attached to it. I wrote about this feature on another SO Question. you can read all about it here.