[英]VC++ dll code region not updated : VS2010
I have copied a dll project and started using it with visual studio 2010. I am facing a strange problem. 我已经复制了一个dll项目,并开始在Visual Studio 2010中使用它。我面临一个奇怪的问题。 Any additional code I add inside any of the function is not getting executed.
我在任何函数中添加的任何其他代码均未执行。 The project is building fine.
该项目建设良好。 No errors.
没有错误。 But when I use the dll with an application, none of the code which I added gets executed.
但是,当我将dll与应用程序一起使用时,添加的代码均不会执行。 for example
例如
int f1()
{
printf("a");
}
is the old code. 是旧的代码。
New code 新密码
int f1()
{
printf("a");
printf("b");
}
When I call f1() from an app which references the dll, I stil get a printed. 当我从引用dll的应用程序中调用f1()时,仍然打印。 b is never printed on screen.
b永远不会在屏幕上打印。 I disabled the optimization option.
我禁用了优化选项。 must be missing a setting in vs2010 project.
必须缺少vs2010项目中的设置。 Any pointer?
有指针吗?
Are you sure you're loading the updated library? 您确定要加载更新的库吗? This sounds a lot like you've got an older copy of your library somewhere and that's the one loaded all the time.
这听起来很像您在某处有一个较旧的库副本,并且一直在加载。 This can get a bit tricky in multi-project solutions building dynamic libraries.
在构建动态库的多项目解决方案中,这可能会有些棘手。
probably an older dll is loaded. 可能是加载了较旧的dll。 check the Dynamic-Link Library Search Order http://msdn.microsoft.com/en-us/library/ms682586%28VS.85%29.aspx
检查动态链接库搜索顺序http://msdn.microsoft.com/zh-cn/library/ms682586%28VS.85%29.aspx
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.