mirror of
https://github.com/GrapheneOS/hardened_malloc.git
synced 2024-12-20 13:24:21 -05:00
fix small allocation canary overwrite test
Overwriting one byte of a canary with 0 has a 1/256 chance of not triggering the expected failure.
This commit is contained in:
parent
5f32942263
commit
acda766e2c
@ -7,7 +7,7 @@ OPTNONE int main(void) {
|
|||||||
if (!p) {
|
if (!p) {
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
*(p + 8 + 7) = 0;
|
*(p + 8 + 7) ^= 1;
|
||||||
free(p);
|
free(p);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user