2011年(17)
分类: C/C++
2011-08-19 16:10:26
今天想去调试几个以前写的ActiveX插件,发现居然无法进入断点。几番搜索之下,最终的解决方案如下:
在注册表中增加一个键值:
1) Browse to HKEY_LOCALMACHINE -> SOFTWARE -> Microsoft -> Internet Explorer -> Main
2) Add a dword under this key called TabProcGrowth
3) Set TabProcGrowth to 0
这么做的原因如下:
IE 8 has a feature called Loosely-Coupled Internet Explorer (LCIE) which results in IE running across multiple processes.
http://www.microsoft.com/windows/internet-explorer/beta/readiness/developers-existing.aspx#lcie
Older versions of the Visual Studio Debugger get confused by this and cannot figure out how to attach to the correct process. You can work around this by disabling the process growth feature of LCIE.
也就是说IE8 有一个LCIE特性,使得IE以多进程的形式运行,旧版的VS调试器会因此产生错乱,不能够获取正确的线程,因此需要禁用该特性。