summaryrefslogtreecommitdiff
path: root/src/dged/hash.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/dged/hash.h')
-rw-r--r--src/dged/hash.h14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/dged/hash.h b/src/dged/hash.h
index 0fd689b..60b6d6a 100644
--- a/src/dged/hash.h
+++ b/src/dged/hash.h
@@ -1,11 +1,11 @@
+#ifndef _HASH_H
+#define _HASH_H
+
#include <stdint.h>
-static uint32_t hash_name(const char *s) {
- unsigned long hash = 5381;
- int c;
+#include "s8.h"
- while ((c = *s++))
- hash = ((hash << 5) + hash) + c; /* hash * 33 + c */
+uint32_t hash_name(const char *s);
+uint32_t hash_name_s8(struct s8 s);
- return hash;
-}
+#endif