Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / clang / test / Analysis / diagnostics / sarif-diagnostics-taint-test.c
blobb1042f9034d7d70edad0dc411db5d27e9d3fac68
1 // RUN: %clang_analyze_cc1 -analyzer-checker=alpha.security.taint,debug.TaintTest %s -verify -analyzer-output=sarif -o - | %normalize_sarif | diff -U1 -b %S/Inputs/expected-sarif/sarif-diagnostics-taint-test.c.sarif -
2 #include "../Inputs/system-header-simulator.h"
4 int atoi(const char *nptr);
6 void f(void) {
7 char s[80];
8 scanf("%s", s);
9 int d = atoi(s); // expected-warning {{tainted}}
12 int main(void) {
13 f();
14 return 0;