mirror of
https://github.com/python/cpython.git
synced 2025-08-31 14:07:50 +00:00
ssue #19183: Implement PEP 456 'secure and interchangeable hash algorithm'.
Python now uses SipHash24 on all major platforms.
This commit is contained in:
parent
fe32aec25a
commit
985ecdcfc2
27 changed files with 1029 additions and 242 deletions
|
@ -897,7 +897,7 @@ bytes_hash(PyBytesObject *a)
|
|||
{
|
||||
if (a->ob_shash == -1) {
|
||||
/* Can't fail */
|
||||
a->ob_shash = _Py_HashBytes((unsigned char *) a->ob_sval, Py_SIZE(a));
|
||||
a->ob_shash = _Py_HashBytes(a->ob_sval, Py_SIZE(a));
|
||||
}
|
||||
return a->ob_shash;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue