bdwain
bdwain

Reputation: 1745

debugging an inproc com server running in dllhost.exe

I am writing an inproc com dll that runs in the dllhost.exe surrogate, but I am running into an issue debugging it.

if there were multiple dllhost.exe's running at once, it would be annoying to find the right one to attach a debugger to. Is there an easy way to identify yours if a lot are running?

Thanks

Upvotes: 4

Views: 1683

Answers (2)

sharptooth
sharptooth

Reputation: 170489

There's an alternative strategy. Just don't try to identify which to attach to. Set a breakpoint in your code and attach to all dllhost.exe processes - when a breakpoint is hit that process will pause under debugger.

Upvotes: 0

pepsi
pepsi

Reputation: 6865

Process explorer (http://technet.microsoft.com/en-us/sysinternals/bb896653) has convenient feature that allows you to look at which processes have loaded which DLLs. You can also do a search for DLLs in all running processes.

Sysinternals also has a command line utility called ListDLLs (http://technet.microsoft.com/en-us/sysinternals/bb896656) that should work for you.

Once you find the PID of the process that has your DLL, you can attach to it.

Upvotes: 1

Related Questions