/* This is just the sdbm hash function with a user-supplied seed and final size parameter.  */
static unsigned int hash_string(unsigned int seed, const char *data, unsigned int mod)
/* This is just the sdbm hash function with a user-supplied seed and final size parameter.  */
static unsigned int hash_string(unsigned int seed, const char *data, unsigned int mod)
{
	unsigned char c;
	while ((c = *data++) != 0) {
		seed = (seed << 16) + (seed << 6) - seed + c;
	}
	return seed % mod;
}