diff options
author | Disch, Simon <simon_disch@mentor.com> | 2015-04-17 09:59:05 +0200 |
---|---|---|
committer | Guy Sagnes <guy.sagnes@continental-corporation.com> | 2015-04-22 17:35:26 +0200 |
commit | bb590bf9ff16b294338b44b866c1ad0ed4e4683c (patch) | |
tree | c6723ca5cfc48faadca73a061dfd910a953f59cc /src/key-value-store/hashtable/qhash.c | |
parent | 1b23e610576f9212061008df2a6cb065982a9c97 (diff) | |
download | persistence-common-object-bb590bf9ff16b294338b44b866c1ad0ed4e4683c.tar.gz |
removed MD5 hash functions
Diffstat (limited to 'src/key-value-store/hashtable/qhash.c')
-rw-r--r-- | src/key-value-store/hashtable/qhash.c | 36 |
1 files changed, 0 insertions, 36 deletions
diff --git a/src/key-value-store/hashtable/qhash.c b/src/key-value-store/hashtable/qhash.c index e7709aa..e070306 100644 --- a/src/key-value-store/hashtable/qhash.c +++ b/src/key-value-store/hashtable/qhash.c @@ -43,45 +43,9 @@ #include <errno.h> #include <sys/types.h> #include <sys/stat.h> -#include "md5.h" #include "qhash.h" /** - * Calculate 128-bit(16-bytes) MD5 hash. - * - * @param data source object - * @param nbytes size of data - * @param retbuf user buffer. It must be at leat 16-bytes long. - * - * @return true if successful, otherwise false. - * - * @code - * // get MD5 - * unsigned char md5hash[16]; - * qhashmd5((void*)"hello", 5, md5hash); - * - * // hex encode - * char *md5ascii = qhex_encode(md5hash, 16); - * printf("Hex encoded MD5: %s\n", md5ascii); - * free(md5ascii); - * @endcode - */ -bool qhashmd5(const void *data, size_t nbytes, void *retbuf) { - if (data == NULL || retbuf == NULL) { - errno = EINVAL; - return false; - } - - MD5_CTX context; - MD5Init(&context); - MD5Update(&context, (unsigned char *) data, (unsigned int) nbytes); - MD5Final(retbuf, &context); - - return true; -} - - -/** * Get 32-bit Murmur3 hash. * * @param data source data |