Commit cfea1cf4 authored by Sage Weil's avatar Sage Weil

ceph: small cleanup in hash function

Signed-off-by: default avatarSage Weil <sage@newdream.net>
parent b9bfb93c
...@@ -85,7 +85,7 @@ unsigned ceph_str_hash_linux(const char *str, unsigned length) ...@@ -85,7 +85,7 @@ unsigned ceph_str_hash_linux(const char *str, unsigned length)
unsigned long hash = 0; unsigned long hash = 0;
unsigned char c; unsigned char c;
while (length-- > 0) { while (length--) {
c = *str++; c = *str++;
hash = (hash + (c << 4) + (c >> 4)) * 11; hash = (hash + (c << 4) + (c >> 4)) * 11;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment