repo.or.cz
/
clang.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
StmtPrinter: factor out arg printing code to PrintCallArgs
[clang.git]
/
test
/
Analysis
/
null-deref-ps-region.c
blob
0199d20fdbb2c9c65cab30166f7cc29e579d0d61
1
// RUN: %clang_cc1 -analyze -analyzer-experimental-internal-checks -std=gnu99 -analyzer-check-objc-mem -analyzer-store=region -verify %s
2
3
4
// The store for 'a[1]' should not be removed mistakenly. SymbolicRegions may
5
// also be live roots.
6
void
f14
(
int
*
a
) {
7
int
i
;
8
a
[
1
] =
1
;
9
i
=
a
[
1
];
10
if
(
i
!=
1
) {
11
int
*
p
=
0
;
12
i
= *
p
;
// no-warning
13
}
14
}