X-Git-Url: https://mattmccutchen.net/rsync/rsync.git/blobdiff_plain/d6e6333a02a900c2863200a0feff4349d4003a8d..4ecf3e067151e45dc7dead9862416722dcb4a20f:/hashtable.c diff --git a/hashtable.c b/hashtable.c index c5ba0f58..d2f5948b 100644 --- a/hashtable.c +++ b/hashtable.c @@ -1,7 +1,7 @@ /* * Routines to provide a memory-efficient hashtable. * - * Copyright (C) 2007 Wayne Davison + * Copyright (C) 2007-2008 Wayne Davison * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -104,7 +104,9 @@ void *hashtable_find(struct hashtable *tbl, int64 key, int allocate_if_missing) a = b = c = 0xdeadbeef + (8 << 2); #define rot(x,k) (((x)<<(k)) ^ ((x)>>(32-(k)))) +#if SIZEOF_INT64 >= 8 b += (uint32)(key >> 32); +#endif a += (uint32)key; c ^= b; c -= rot(b, 14); a ^= c; a -= rot(c, 11);