[clang-tools-extra] [clang-tidy] New bugprone-unsafe-format-string check (PR #168691)
via cfe-commits
cfe-commits at lists.llvm.org
Tue Dec 2 14:26:54 PST 2025
================
@@ -202,6 +202,12 @@ New checks
Detects default initialization (to 0) of variables with ``enum`` type where
the enum has no enumerator with value of 0.
+- New :doc:`bugprone-unsafe-format-string
+ <clang-tidy/checks/bugprone/unsafe-format-string>` check.
+
+ Detects usage of vulnerable printf and scanf-like format
+ string functions with unbounded ``%s`` specifiers that can cause buffer overflows.
----------------
EugeneZelenko wrote:
```suggestion
Detects usage of vulnerable ``printf`` and ``scanf``-like format string
functions with unbounded ``%s`` specifiers that can cause buffer overflows.
```
https://github.com/llvm/llvm-project/pull/168691
More information about the cfe-commits
mailing list