当前位置:网站首页>Severity code description the project file line prohibits the display of status error c4996 fopen ('fscanf ', StrCmp): this function or variable may be unsafe The most comprehensive solution
Severity code description the project file line prohibits the display of status error c4996 fopen ('fscanf ', StrCmp): this function or variable may be unsafe The most comprehensive solution
2022-07-04 00:27:00 【Gulu a mouthful of warm water】
solve fopen、fscanf stay VS Replace with fopen_s、fscanf_s The most complete solution -------------- ps: In the use of MFC The problems mentioned above are encountered in the course of the project , There are three ways to solve this problem : Add... To the front of the program #define _CRT_SECURE_NO_DEPRECATE;
Method 2 : Add... To the front of the program #define _CRT_SECURE_NO_WARNINGS;
Method 3 : Add... To the front of the program #pragma warning(disable:4996);
Method four : hold scanf、scanf Change it to scanf_s、fopen_s, Specific method please Baidu ;
Method five : There's no need to add that line of code to the front of the program , Just uncheck when you create a new project “SDL Check ” that will do ;
Methods six : If the project is established , Close... In project properties SDL It's OK ;
Methods seven : Just set up the project ; Put the macro definition of error report in Item attribute -- C/C++-- The preprocessor -- Preprocessor definition ;
Methods eight : stay Item attribute -- c/c++ -- Command line add to :/D _CRT_SECURE_NO_WARNINGS That's it .
边栏推荐
- Sorry, Tencent I also refused
- NLP pre training technology development
- Idea set class header comments
- Research Report on the scale prediction of China's municipal engineering industry and the prospect of the 14th five year plan 2022-2028
- It is forbidden to splice SQL in code
- Regular expressions and text processors for shell programming
- Interview script of Software Test Engineer
- [CSDN Q & A] experience and suggestions
- Development and application of fcitx functional plug-ins
- Suggestions for improving code quality
猜你喜欢
How to make recv have a little temper?
[Mongodb] 2. Use mongodb --------- use compass
Several ways to set up a blog locally [attach relevant software download links]
STM32 key light
NLP pre training technology development
ESP Arduino playing with peripherals (V) basic concept of interrupt and timer interrupt
Cannot build artifact 'test Web: War expanded' because it is included into a circular depend solution
Is it really possible that the monthly salary is 3K and the monthly salary is 15K?
MySQL 8.0.12 error: error 2013 (HY000): lost connection to MySQL server during query
Analysis: misunderstanding of choosing WMS warehouse management system
随机推荐
What is the potential of pocket network, which is favored by well-known investors?
Report on prospects and future investment recommendations of China's assisted reproductive industry, 2022-2028 Edition
MySQL winter vacation self-study 2022 12 (1)
How to trade spot gold safely?
Introducing Software Testing
Advanced C language - pointer 2 - knowledge points sorting
What are the application fields of digital twins in industry?
Report on the construction and development mode and investment mode of sponge cities in China 2022-2028
[PHP basics] cookie basics, application case code and attack and defense
2022 system integration project management engineer examination knowledge points: software development model
Kubedl hostnetwork: accelerating the efficiency of distributed training communication
Data storage - interview questions
What is the difference between NFT, SFT and dnft? How to build NFT platform applications?
Detailed explanation of the relationship between Zhongtai, wechat and DDD
I would like to ask how the top ten securities firms open accounts? Is it safe to open an account online?
Vscode regular match replace console log(.*)
It is the most difficult to teach AI to play iron fist frame by frame. Now arcade game lovers have something
Kubedl hostnetwork: accelerating the efficiency of distributed training communication
[2021]NeRF in the Wild: Neural Radiance Fields for Unconstrained Photo Collections
AI Challenger 2018 text mining competition related solutions and code summary