develop.uap-core.de/git
/
uwplayer.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
add single instance mode
[uwplayer.git]
/
ucx
/
hash_key.c
diff --git
a/ucx/hash_key.c
b/ucx/hash_key.c
index
c1bd430
..
a219dca
100644
(file)
--- a/
ucx/hash_key.c
+++ b/
ucx/hash_key.c
@@
-30,7
+30,7
@@
#include <string.h>
void cx_hash_murmur(CxHashKey *key) {
#include <string.h>
void cx_hash_murmur(CxHashKey *key) {
- unsigned char const *data = key->data
.cbytes
;
+ unsigned char const *data = key->data;
if (data == NULL) {
// extension: special value for NULL
key->hash = 1574210520u;
if (data == NULL) {
// extension: special value for NULL
key->hash = 1574210520u;
@@
-71,7
+71,7
@@
void cx_hash_murmur(CxHashKey *key) {
h *= m;
__attribute__((__fallthrough__));
default: // do nothing
h *= m;
__attribute__((__fallthrough__));
default: // do nothing
- ;
+
;
}
h ^= h >> 13;
}
h ^= h >> 13;
@@
-83,7
+83,7
@@
void cx_hash_murmur(CxHashKey *key) {
CxHashKey cx_hash_key_str(char const *str) {
CxHashKey key;
CxHashKey cx_hash_key_str(char const *str) {
CxHashKey key;
- key.data
.cstr
= str;
+ key.data = str;
key.len = str == NULL ? 0 : strlen(str);
cx_hash_murmur(&key);
return key;
key.len = str == NULL ? 0 : strlen(str);
cx_hash_murmur(&key);
return key;
@@
-94,7
+94,7
@@
CxHashKey cx_hash_key_bytes(
size_t len
) {
CxHashKey key;
size_t len
) {
CxHashKey key;
- key.data
.cbytes
= bytes;
+ key.data = bytes;
key.len = len;
cx_hash_murmur(&key);
return key;
key.len = len;
cx_hash_murmur(&key);
return key;
@@
-105,7
+105,7
@@
CxHashKey cx_hash_key(
size_t len
) {
CxHashKey key;
size_t len
) {
CxHashKey key;
- key.data
.cobj
= obj;
+ key.data = obj;
key.len = len;
cx_hash_murmur(&key);
return key;
key.len = len;
cx_hash_murmur(&key);
return key;