summaryrefslogtreecommitdiffstats
path: root/hashfuncs.c
diff options
context:
space:
mode:
authorKamil Kaminski <kamilkss@gmail.com>2010-11-28 23:52:09 -0600
committerKamil Kaminski <kamilkss@gmail.com>2010-11-28 23:52:09 -0600
commit2b125bbbf3ff8c5e57e2ee2b002dc19205bb9a47 (patch)
tree81977372fcebc8dcb5cbfa2b235434d8cc78f9a0 /hashfuncs.c
parent4466182539196d2a2379481f08f0b0cacdf8ca75 (diff)
downloadhashtable-2b125bbbf3ff8c5e57e2ee2b002dc19205bb9a47.tar.gz
hashtable-2b125bbbf3ff8c5e57e2ee2b002dc19205bb9a47.tar.bz2
hashtable-2b125bbbf3ff8c5e57e2ee2b002dc19205bb9a47.zip
trivial
Diffstat (limited to 'hashfuncs.c')
-rw-r--r--hashfuncs.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/hashfuncs.c b/hashfuncs.c
index 01a1be1..798d5b8 100644
--- a/hashfuncs.c
+++ b/hashfuncs.c
@@ -154,8 +154,8 @@ unsigned int aphash(const char *key)
for ( ; *key; key++)
{
- hash ^= ((i & 1) == 0) ? ( (hash << 7) ^ (*key) * (hash >> 3)) :
- (~((hash << 11) + ((*key) ^ (hash >> 5))));
+ hash ^= ((i & 1) == 0) ? ( (hash << 7) ^ (const unsigned int) (*key) * (hash >> 3)) :
+ (~((hash << 11) + ((const unsigned int) (*key) ^ (hash >> 5) )));
}
return hash;