我正在尝试调试一些行为奇怪的 .NET 可执行文件(我没有源代码)。
使用 WinDBG 附加到它时,我注意到它抛出了 IndexOutOfRangeException。
我试图了解哪一行实际上引发了这个异常——我怎样才能看到导致这个异常的索引访问?
我可以使用 !CLRStack 查看堆栈,但它并没有引导我找到抛出它的确切代码行。
这就是我在 !CLRStack 中看到的:
0015ec9c 6f1459d8 System.Management.Instrumentation.InstrumentedAssembly+TypeInfo.Fire(System.Object)
0015eccc 6f144bdc System.Management.Instrumentation.InstrumentedAssembly.Fire(System.Type, System.Object)
0015ecd8 6f145164 System.Management.Instrumentation.InstrumentedAssembly.Fire(System.Object)
0015ecec 6f142268 System.Management.Instrumentation.Instrumentation.Fire(System.Object)
0015ecf8 034ce47b InstallerLibrary.InstallerInterface.WMIEventGenerator.FireEvent(System.Object)
0015ed2c 0393970c InstallerLibrary.InstallerInterface.WMIEventGenerator.GenerateServerAlive(UInt32)
0015ed54 039396b7 InstallerLibrary.InstallerInterface.InstallerInterface.NotifyServerAlive(UInt32)
0015ed60 03939655 InstallerLibrary.InstallaterManager.NotifyServerAlive(UInt32)
0015ed88 00580f13 InstallerInit.Class1.Main(System.String[])