vs2012 error c4996 'fopen'

百度经验:http://jingyan.baidu.com/article/ce436649fd61543773afd32e.html

在vs2012依然好用

error C4996: 'fopen': This function or variable may be unsafe. Consider using fopen_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.

1>f:\program files (x86)\microsoft visual studio 12.0\vc\include\stdio.h(211) : 参见“fopen”的声明

解决方案:

文件属性-》C/C++-》预处理器-》预处理定义 添加_CRT_SECURE_NO_WARNINGS


以后遇到这种问题是不是加个这个东东就好了

发布了32 篇原创文章 · 获赞 16 · 访问量 7万+
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章