-
Notifications
You must be signed in to change notification settings - Fork 21
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Murmur3 gives out different hash values for the same input #7
Comments
@KingBoomie The byte-array is modified after the first run of the hash pass: @Test
public void test() {
byte[] data2 = {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1};
byte[] data3 = {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1};
final long seed = new Random().nextLong();
long[] initial = Murmur3.hash_x64_128(data2, data2.length, seed);
System.out.println(Arrays.toString(data2));
Assert.assertArrayEquals(data2, data3); // this fails
} The
I will debug further to see why this happens. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Running in jshell
returns
Expected all return values to be equal.
running OracleJDK 12.0.2.
The text was updated successfully, but these errors were encountered: