mirror of
https://github.com/GrapheneOS/hardened_malloc.git
synced 2024-12-24 23:19:35 -05:00
random: fix whitespace issue
This commit is contained in:
parent
2fbf7bb25e
commit
dfa49481e5
4
random.c
4
random.c
@ -102,7 +102,7 @@ u16 get_random_u16_uniform(struct random_state *state, u16 bound) {
|
|||||||
if (leftover < bound) {
|
if (leftover < bound) {
|
||||||
u16 threshold = -bound % bound;
|
u16 threshold = -bound % bound;
|
||||||
while (leftover < threshold) {
|
while (leftover < threshold) {
|
||||||
random = get_random_u16(state);
|
random = get_random_u16(state);
|
||||||
multiresult = random * bound;
|
multiresult = random * bound;
|
||||||
leftover = (u16)multiresult;
|
leftover = (u16)multiresult;
|
||||||
}
|
}
|
||||||
@ -129,7 +129,7 @@ u64 get_random_u64_uniform(struct random_state *state, u64 bound) {
|
|||||||
if (leftover < bound) {
|
if (leftover < bound) {
|
||||||
u64 threshold = -bound % bound;
|
u64 threshold = -bound % bound;
|
||||||
while (leftover < threshold) {
|
while (leftover < threshold) {
|
||||||
random = get_random_u64(state);
|
random = get_random_u64(state);
|
||||||
multiresult = random * bound;
|
multiresult = random * bound;
|
||||||
leftover = multiresult;
|
leftover = multiresult;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user