(__hash_string): Zero-extend each char from the string; the old code did a sign-extend on some platforms.

This commit is contained in:
Ulrich Drepper 2003-10-24 03:22:26 +00:00
parent e97bfee1b1
commit d0f1175e94

View File

@ -35,7 +35,7 @@ __hash_string (str_param)
while (*str != '\0')
{
hval <<= 4;
hval += (unsigned long int) *str++;
hval += (unsigned char) *str++;
g = hval & ((unsigned long int) 0xf << (HASHWORDBITS - 4));
if (g != 0)
{