Skip to content

Commit

Permalink
Run smhasher test with weaker keys
Browse files Browse the repository at this point in the history
  • Loading branch information
tkaitchuck authored Oct 25, 2022
1 parent fc7b36b commit 2c1a088
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion smhasher/ahash-cbindings/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,6 @@ use std::hash::{BuildHasher};
#[no_mangle]
pub extern "C" fn ahash64(buf: *const (), len: usize, seed: u64) -> u64 {
let buf: &[u8] = unsafe { slice::from_raw_parts(buf as *const u8, len) };
let build_hasher = RandomState::with_seed(seed as usize);
let build_hasher = RandomState::with_seeds(seed, seed, seed, seed);
build_hasher.hash_one(&buf)
}

0 comments on commit 2c1a088

Please sign in to comment.