xref: /illumos-gate/usr/src/tools/smatch/src/validation/mem2reg/undef01.c (revision f52943a93040563107b95bccb9db87d9971ef47d)
1 static void foo(void)
2 {
3 	int *b;
4 	for (;;)
5 		*b++ = 0;
6 }
7 
8 /*
9  * check-name: undef01
10  * check-command: sparse -Wmaybe-uninitialized $file
11  * check-known-to-fail
12  *
13  * check-error-start
14 crazy04.c:3:13: warning: variable 'b' may be uninitialized
15  * check-error-end
16  */
17