for (host_ptr = vl->host; *host_ptr != 0; host_ptr++)
{
- /* 251 is the largest prime smaller than 256. */
- hash_val = (hash_val * 251) + ((uint32_t) *host_ptr);
+ /* 2184401929 is some appropriately sized prime number. */
+ hash_val = (hash_val * UINT32_C (2184401929)) + ((uint32_t) *host_ptr);
}
DEBUG ("hashed match: host = %s; hash_val = %"PRIu32";", vl->host, hash_val);