ceph: small cleanup in hash function

Signed-off-by: Sage Weil <sage@newdream.net>
This commit is contained in:
Sage Weil 2009-11-18 16:50:55 -08:00
parent b9bfb93ce2
commit cfea1cf42b

View File

@ -85,7 +85,7 @@ unsigned ceph_str_hash_linux(const char *str, unsigned length)
unsigned long hash = 0;
unsigned char c;
while (length-- > 0) {
while (length--) {
c = *str++;
hash = (hash + (c << 4) + (c >> 4)) * 11;
}