mirror of
https://github.com/isc-projects/bind9.git
synced 2026-05-26 19:34:04 -04:00
fix: dev: Update fxhash constants
The fxhash implementation was missing a constant for 32-bit platforms. This has been fixed. Constant for 64-bit platform was update to match the current Rust constants. Merge branch 'ondrej/update-fxhash-constants' into 'main' See merge request isc-projects/bind9!10894
This commit is contained in:
commit
492fd02409
1 changed files with 5 additions and 1 deletions
|
|
@ -32,7 +32,11 @@
|
|||
#include <isc/bit.h>
|
||||
|
||||
/* The constant K from Rust's fxhash */
|
||||
#define K 0x9e3779b97f4a7c15ull
|
||||
#if SIZE_MAX == UINT64_MAX
|
||||
#define K UINT64_C(0x517cc1b727220a95)
|
||||
#else
|
||||
#define K UINT32_C(0x9e3779b9)
|
||||
#endif
|
||||
|
||||
static inline size_t
|
||||
fx_add_to_hash(size_t hash, size_t i) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue