Remove unnecessary seed modifcation

Because the first step of wyrand is an addition with a constant, a non-zero seed is not required
This commit is contained in:
ironhaven 2023-10-17 08:37:08 +00:00 committed by John Nunley
parent a8f98b445d
commit 63175fa2e2
1 changed files with 1 additions and 2 deletions

View File

@ -193,8 +193,7 @@ fn random_seed() -> Option<u64> {
let mut hasher = DefaultHasher::new();
Instant::now().hash(&mut hasher);
thread::current().id().hash(&mut hasher);
let hash = hasher.finish();
Some((hash << 1) | 1)
Some(hasher.finish())
}
#[cfg(all(