User: | Jiri Slaby |
Error type: | Reachable Error Location |
Error type description: | A specified error location is reachable in some program path |
File location: | loops/nec40_safe.i |
Line in file: | 3 |
Project: | SV-COMP 2013 |
Project version: | 2.6.28 |
Tools: |
Manual Work
|
Entered: | 2013-01-17 16:57:54 UTC |
1void __VERIFIER_assert(int cond) { 2 if (!(cond)) { 3 ERROR: goto ERROR; 4 } 5 return; 6} 7int __VERIFIER_nondet_int(); 8 9 char x[100], y[100]; 10 int i,j,k; 11 12void main() { 13 k = __VERIFIER_nondet_int(); 14 15 i = 0; 16 while(x[i] != 0){ 17 y[i] = x[i]; 18 i++; 19 } 20 y[i] = 0; 21 22 if(k >= 0 && k < i) 23 if(y[k] != 0) 24 {__VERIFIER_assert(0);} 25}