gets() function is not available in Visual studio 2015 community

后端 未结 4 1922
-上瘾入骨i
-上瘾入骨i 2021-02-08 13:29

I have faced a compiler error(c3861) in my newly installed Visual studio community 2015 IDE:

I just want to use gets() function from stdio.h library, a

4条回答
  •  北恋
    北恋 (楼主)
    2021-02-08 13:50

    if you are looking forward to learn about

    buffer overflow vulnerability

    you simply can use it and anther unsafe functions by the fallowing steps

    1. from the solution explorer right click on the project and choose properties
    2. navigate to Configuration Properties >> C/C++ >> Advanced
    3. change Compile As value to Compile as C Code (/TC)
    4. (optional) if you would like to disable the warning just put its warning number in disable specific warning

提交回复
热议问题