]> andersk Git - splint.git/blame - test/tainted/taintedimplicit.c
Fixed manual csvoverwrite.
[splint.git] / test / tainted / taintedimplicit.c
CommitLineData
98ed3b22 1char *taintme (char *s)
2 /*@ensures result:taintedness = s:taintedness@*/
3{
4 char *res = (char *) malloc (sizeof (*res) * strlen (s));
5 assert (res != NULL);
6 strcpy (res, s);
7 return res;
8}
9
10void safecall (/*@untainted@*/ char *s)
11{
12 (void) system (taintme (s)); /* okay */
13}
14
15void dangerouscall (/*@tainted@*/ char *s)
16{
17 (void) system (taintme (s)); /* error */
18}
This page took 0.202599 seconds and 5 git commands to generate.