您的位置:首页 > 其它

'scanf' was declared deprecated,

2014-10-03 10:22 393 查看


问:我在用vs2005写c时,遇到这样一个warning:

我在用vs2005写c时,遇到这样一个warning:
'scanf' was declared deprecated,


答:这个warning不会导致错误。很正常的

warning C4996: 'scanf': This function or variable may be unsafe. Consider using scanf_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
因为scanf的声明在VS2005中被认为是不安全的,让你使用scanf_S来代替。你可以使用帮助来获取细节。
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: