Updating the get function in the C++ interface.
[awesomized/libmemcached] / libmemcached / crc.c
index ed22adc46dd868c97120384db7a19abeb31ec714..5c586bf0ab8663cea7ce90a79a2a11abb4d5be96 100644 (file)
@@ -77,8 +77,7 @@ static const uint32_t crc32tab[256] = {
 uint32_t hash_crc32(const char *key, size_t key_length)
 {
   uint32_t x;
-  uint32_t crc;
-  crc= ~0;
+  uint32_t crc= UINT32_MAX;
 
   for (x= 0; x < key_length; x++)
     crc= (crc >> 8) ^ crc32tab[(crc ^ (key[x])) & 0xff];