代码之家  ›  专栏  ›  技术社区  ›  Oskar

如何判断使用windbg进行呼叫的非安全方法。DispatchMessage?

  •  0
  • Oskar  · 技术社区  · 15 年前

    非常感谢

    奥斯卡

    0:057> !clrstack
    OS Thread Id: 0x17f8 (57)
    ESP       EIP     
    1393f1ac 2070a64a [NDirectMethodFrameStandalone: 1393f1ac] System.Windows.Forms.UnsafeNativeMethods.DispatchMessageA(MSG ByRef)
    1393f1bc 04851c91 System.Windows.Forms.Application+ComponentManager.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.FPushMessageLoop(Int32, Int32, Int32)
    1393f258 04851276 System.Windows.Forms.Application+ThreadContext.RunMessageLoopInner(Int32, System.Windows.Forms.ApplicationContext)
    1393f2a0 048507e3 System.Windows.Forms.Application+ThreadContext.RunMessageLoop(Int32, System.Windows.Forms.ApplicationContext)
    1393f2d0 0485062f System.Windows.Forms.Application.Run()
    
    2 回复  |  直到 15 年前
        1
  •  1
  •   Oskar    15 年前
    !dumpstack 
    

    这样做的诀窍是,将详细的堆栈跟踪到非托管dll中

        2
  •  0
  •   Ana Betts    15 年前

    kn100 将为您提供本机堆栈,但它似乎正在调用 DispatchMessage

    打开MSG结构,以便查看窗口及其试图发送的消息,然后在代码中找到相应的事件处理程序。