[PATCH] D91000: MSC24-C Obsolescent Functions check

Koller Tamás via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Sat Nov 7 03:24:51 PST 2020


ktomi996 created this revision.
ktomi996 added reviewers: aaron.ballman, alexfh, hokein, njames93.
ktomi996 added a project: clang-tools-extra.
Herald added subscribers: cfe-commits, mgorny.
Herald added a project: clang.
ktomi996 requested review of this revision.

This checker guards against using some vulnerable C functions which are mentioned in MSC24-C in obsolescent functions table.
The checker warns only if __STDC_LIB_EXT1__ macro is defined and the value of __STDC_WANT_LIB_EXT1__ macro is 1 in this case it suggests the corresponding functions from Annex K instead the vulnerable function.
https://wiki.sei.cmu.edu/confluence/display/c/MSC24-C.+Do+not+use+deprecated+or+obsolescent+functions


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D91000

Files:
  clang-tools-extra/clang-tidy/cert/CERTTidyModule.cpp
  clang-tools-extra/clang-tidy/cert/CMakeLists.txt
  clang-tools-extra/clang-tidy/cert/ObsolescentFunctionsCheck.cpp
  clang-tools-extra/clang-tidy/cert/ObsolescentFunctionsCheck.h
  clang-tools-extra/clang-tidy/misc/CMakeLists.txt
  clang-tools-extra/clang-tidy/misc/CountFunctionsCheck.cpp
  clang-tools-extra/clang-tidy/misc/CountFunctionsCheck.h
  clang-tools-extra/docs/ReleaseNotes.rst
  clang-tools-extra/docs/clang-tidy/checks/cert-obsolescent-functions.rst
  clang-tools-extra/docs/clang-tidy/checks/list.rst
  clang-tools-extra/test/clang-tidy/cert-obsolescent-functions.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D91000.303631.patch
Type: text/x-patch
Size: 17194 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20201107/45abfda1/attachment-0001.bin>


More information about the cfe-commits mailing list