How to avoid the DbgCommand command being written to the logfile

孤者浪人 提交于 2019-12-01 20:38:32

Use pykd.typedVar class. It is specialy designed for such cases

try to change:

dt 0x000000eab87488f0 CMap<int,int,CUIntArray *,CUIntArray *> m_nCount

to:

var =  typedVar("CMap<int,int,CUIntArray *,CUIntArray *>", 0x000000eab87488f0 )
print var
print var.m_nCount
print var.m_nCount * 2

You can get access to any filed of CMap class and work with its as they are natural python types

If you are going to get typedVar multiple times you can cache type information to avoid performance problems:

CMap = typeInfo("CMap<int,int,CUIntArray *,CUIntArray *>")
var = typedVar( CMap, 0x000000eab87488f0 )

Try to enumerate types for your module ( with wildcard mask ) and find exact symbol name for CMap.

app = pykd.module("<application_name>")
for tp in app.enumTypes("CMap*"):
   print tp

I can try to reproduce an issue on a small example, but I need to know your Visual Studio version.

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!