repo.or.cz
/
official-gcc.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
[RISC-V] Avoid unnecessary extensions when value is already extended
[official-gcc.git]
/
gcc
/
testsuite
/
c-c++-common
/
analyzer
/
taint-modulus-1.c
blob
ed286fa341cdeb769bc860a8cecdcc0e1c5d000a
1
#define SIZE 16
2
char
buf
[
SIZE
];
3
4
__attribute__
((
tainted_args
))
5
char
test_sanitized_by_modulus
(
int
val
)
6
{
7
return
buf
[
val
%
SIZE
];
/* { dg-bogus "use of attacker-controlled value" } */
8
}