开发者

Set breakpoint on COM class method in windbg

Is there some way, similar to "bm Module!Symbol" to set a breakpoint on a specific method of a COM class in windbg? It looks like a COM DLL only exports four symbols (DllCanUnloadNow, DllGetC开发者_运维问答lassObject, DllRegisterServer, and DllUnregisterServer), so the usual "bm" approach doesn't work. I'm assuming there's some other way to do it, but I haven't been able to find it in the past hour or so.


You should be able to use bu (unresolved breakpoint). I believe the syntax is as follows, but my memory may be rusty:

bu MyDll!MyClass::MyMethod


COM methods are still regular symbols, even if they're not exported. Say you have MyFoo.dll which contains a MyBar::Baz() method. In WinDbg if you have symbols loaded you can eXamine the symbols with:

X MyFoo!*Baz*
00007ffa`204cbb00 MyFoo!MyBar::Baz (void)

You can set a breakpoint on it with

bp MyFoo!MyBar::Baz
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜