如何通过程序集和methoddef找出方法名称?

时间:2012-02-27 13:36:49

标签: .net windows-server-2008

使用Windows XP在计算机上开发的应用程序在Windows Server 2008的目标计算机上运行得很好。即,它无法正常启动以下信息:

Description:

  Stopped working


Problem signature:

  Problem Event Name:   CLR20r3

  Problem Signature 01: neolant.asrm.rcpfreshner.service

  Problem Signature 02: 1.0.7.0

  Problem Signature 03: 4f4b66d2

  Problem Signature 04: mscorlib

  Problem Signature 05: 2.0.0.0

  Problem Signature 06: 4bf4c743

  Problem Signature 07: e47

  Problem Signature 08: 20e

  Problem Signature 09: Exception

  OS Version:   6.0.6002.2.2.0.272.7

  Locale ID:    1049

我想从中提取所有可能的信息,这意味着我需要知道mscorlib中有哪种方法有e47的methoddef。

如何检索此信息?

2 个答案:

答案 0 :(得分:4)

您可以使用ildasm(Microsoft中间语言反汇编程序)。在ildasm中打开程序集,然后从主菜单中选择View -> MetaInfo -> Show!。您将看到带有* Def / * Ref标识符的程序集元数据。

答案 1 :(得分:1)

Navreen对如何解码“Watson Bucket”转储有很好的描述。

http://naveensrinivasan.github.io/2010/11/17/decoding-clr20r3-.net-exception---using-mono-cecil/

他还有一个脚本,它使用Mono Cecil自动将Watson Bucket解码为发生问题的IL转储。