projects
/
m6w6
/
libmemcached
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
|
github
raw
|
inline
| side by side
Update memcached, fix style in test cases.
[m6w6/libmemcached]
/
libhashkit
/
fnv_64.cc
diff --git
a/libhashkit/fnv_64.cc
b/libhashkit/fnv_64.cc
index 0cfce633047991a83047b529eece2a86281f06af..302215a083ec6ee532945ea58def72e732ef947e 100644
(file)
--- a/
libhashkit/fnv_64.cc
+++ b/
libhashkit/fnv_64.cc
@@
-38,6
+38,8
@@
#include <libhashkit/common.h>
#include <libhashkit/common.h>
+#if __WORDSIZE == 64 && defined(HAVE_FNV64_HASH)
+
/* FNV hash'es lifted from Dustin Sallings work */
static uint64_t FNV_64_INIT= 0xcbf29ce484222325;
static uint64_t FNV_64_PRIME= 0x100000001b3;
/* FNV hash'es lifted from Dustin Sallings work */
static uint64_t FNV_64_INIT= 0xcbf29ce484222325;
static uint64_t FNV_64_PRIME= 0x100000001b3;
@@
-69,3
+71,15
@@
uint32_t hashkit_fnv1a_64(const char *key, size_t key_length, void *)
return hash;
}
return hash;
}
+
+#else
+uint32_t hashkit_fnv1_64(const char *, size_t, void *)
+{
+ return 0;
+}
+
+uint32_t hashkit_fnv1a_64(const char *, size_t, void *)
+{
+ return 0;
+}
+#endif