I want to have deprecation warnings(C4996, the ones caused by calling functions like strcpy) disabled by default in all C/C++ projects in Visual Studio 2019.
There are several ways on the internet on how to do it, but they are all on a per-project basis, the most straightforward way is to add _CRT_SECURE_NO_WARNINGS to the preprocessor definitions. But I want to achieve this effect automatically, without having to fiddle with the project setting each time I make a new project.
I know there must be a way. I don't care how "hacky" the method is. Using the safe variants of the functions isn't an option for me.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.