mirror of
https://github.com/skeeto/endlessh.git
synced 2024-10-05 09:02:00 +02:00
Truncate rand16() result to 16 bits
This commit is contained in:
parent
1583f6e5b3
commit
47b901d9d3
@ -237,7 +237,7 @@ static unsigned
|
||||
rand16(unsigned long s[1])
|
||||
{
|
||||
s[0] = s[0] * 1103515245UL + 12345UL;
|
||||
return s[0] >> 16;
|
||||
return (s[0] >> 16) & 0xffff;
|
||||
}
|
||||
|
||||
static int
|
||||
|
Loading…
Reference in New Issue
Block a user