vessel/core/switch.c
Arija A. 68f46a3d3a
fix(core): (u)int64_t => (s)size_t
Signed-off-by: Arija A. <ari@ari.lt>
2025-06-14 15:13:13 +03:00

23 lines
461 B
C

#include "include/conf.h"
#include <string.h>
#include "include/switch.h"
#include "include/hashing.h"
uint64_t vs_switch_hash(const char *input) {
if (!input) {
return 0;
}
const size_t length = strlen(input);
return vs_xxhash3(input, length, vs_fnv1a(input, length));
}
uint64_t vs_switch_hashn(const char *input, size_t len) {
if (!input) {
return 0;
}
return vs_xxhash3(input, len, vs_fnv1a(input, len));
}