]> andersk Git - splint.git/blame - test/tainted/tainted2.c
Pushed back constraintResolve.c to the previous version.
[splint.git] / test / tainted / tainted2.c
CommitLineData
98ed3b22 1# include <assert.h>
2
3/*@untainted@*/ char *test (int fromuser, /*@untainted@*/ char *def)
4{
5 char *stk = NULL;
6
7 if (fromuser != 0)
8 {
9 stk = malloc (sizeof (char) * strlen (def));
10 assert (stk != NULL);
11 strcpy (stk, def);
12 }
13 else
14 {
15 stk = malloc (sizeof (char) * 128);
16 assert (stk != NULL);
17 (void) fgets (stk, 128, stdin);
18 }
19
20 return stk;
21}
This page took 0.076163 seconds and 5 git commands to generate.