repo.or.cz
/
smatch.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
smatch: relicense to GPLv2+
[smatch.git]
/
validation
/
sm_implied5.c
blob
09b4a13ac9834b564390c536d77e8a50cee9747d
1
struct
ture
{
2
int
a
;
3
};
4
5
int
out_a
;
6
7
void
func
(
void
)
8
{
9
struct
ture
*
aa
;
10
int
a
=
0
;
11
12
if
(
out_a
) {
13
aa
=
returns_nonnull
();
14
a
=
something
();
15
}
16
if
(
a
)
17
aa
->
a
=
1
;
18
aa
->
a
=
0xF00D
;
19
}
20
/*
21
* check-name: Smatch implied #5
22
* check-command: smatch --spammy sm_implied5.c
23
*
24
* check-output-start
25
sm_implied5.c:18 func() error: potentially dereferencing uninitialized 'aa'.
26
* check-output-end
27
*/