tagmap: Try a slightly better hashing function [O. Galibert]

This commit is contained in:
Olivier Galibert 2013-01-03 14:22:27 +00:00
parent c014d27cd6
commit cc0f95bb74

View File

@ -114,8 +114,8 @@ public:
UINT32 hash(const char *string) const
{
UINT32 result = *string++;
for (char c = *string++; c != 0; c = *string++)
result = ((result << 5) | (result >> 27)) + c;
for (UINT8 c = *string++; c != 0; c = *string++)
result = (result*33) ^ c;
return result;
}