我在这个地方下载了一些关于密码过滤器的代码。原始项目是在vs2008和vs2010编译的。我更新到vs2012,发现无法编译。我该如何解决这个问题,谢谢。
这是错误消息:
Error 1 error C2440: '=' : cannot convert from 'char *' to 'TCHAR *' D:\SVN\branch\nobull-branch\util.cpp 72 1 passwdHk
Error 2 error C2664: 'int sprintf_s(char *,size_t,const char *,...)' : cannot convert parameter 1 from 'TCHAR *' to 'char *' D:\SVN\branch\nobull-branch\util.cpp 89 1 passwdHk
Error 3 error C2664: '_strdup' : cannot convert parameter 1 from 'TCHAR *' to 'const char *' D:\SVN\branch\nobull-branch\util.cpp 91 1 passwdHk
Error 4 error C2664: 'strlen' : cannot convert parameter 1 from 'TCHAR *' to 'const char *' D:\SVN\branch\nobull-branch\util.cpp 188 1 passwdHk
Error 5 error C2664: 'pshk_log_write_w' : cannot convert parameter 2 from 'const char [28]' to 'LPCWSTR' D:\SVN\branch\nobull-branch\util.cpp 202 1 passwdHk
Error 6 error C2664: 'strlen' : cannot convert parameter 1 from 'TCHAR *' to 'const char *' D:\SVN\branch\nobull-branch\util.cpp 208 1 passwdHk
Error 7 error C2664: 'strlen' : cannot convert parameter 1 from 'TCHAR *' to 'const char *' D:\SVN\branch\nobull-branch\util.cpp 211 1 passwdHk
Error 8 error C2664: '_strdup' : cannot convert parameter 1 from 'TCHAR *' to 'const char *' D:\SVN\branch\nobull-branch\util.cpp 224 1 passwdHk
Error 9 error C2664: 'strlen' : cannot convert parameter 1 from 'TCHAR *' to 'const char *' D:\SVN\branch\nobull-branch\util.cpp 229 1 passwdHk
Error 10 error C2446: ':' : no conversion from 'const char *' to 'TCHAR *' D:\SVN\branch\nobull-branch\util.cpp 249 1 passwdHk
Error 11 error C2664: 'int _snprintf_s(char *,size_t,size_t,const char *,...)' : cannot convert parameter 1 from 'TCHAR *' to 'char *' D:\SVN\branch\nobull-branch\util.cpp 249 1 passwdHk
Error 12 error C2664: 'int _snprintf_s(char *,size_t,size_t,const char *,...)' : cannot convert parameter 1 from 'TCHAR *' to 'char *' D:\SVN\branch\nobull-branch\util.cpp 254 1 passwdHk