12 static void func (void)
43 d
= malloc(sizeof(*d
));
52 * check-name: Null Dereferences
53 * check-command: smatch --spammy sm_null_deref.c
56 sm_null_deref.c +18 func(6) error: dereferencing undefined: 'aa'
57 sm_null_deref.c +18 func(6) error: potentially derefencing uninitialized 'aa'.
58 sm_null_deref.c +23 func(11) error: dereferencing undefined: 'a'
59 sm_null_deref.c +25 func(13) warn: variable dereferenced before check 'a'
60 sm_null_deref.c +30 func(18) error: dereferencing undefined: 'b'
61 sm_null_deref.c +48 func(36) error: dereferencing undefined: 'd'
62 sm_null_deref.c +48 func(36) error: potential null derefence 'd'.