mirror of
https://github.com/ElementsProject/lightning.git
synced 2026-08-20 13:27:36 +02:00
We have three uses already, about to add a fourth. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
11 lines
270 B
C
11 lines
270 B
C
#ifndef LIGHTNING_COMMON_HASH_STR_H
|
|
#define LIGHTNING_COMMON_HASH_STR_H
|
|
#include "config.h"
|
|
#include <common/pseudorand.h>
|
|
|
|
static inline size_t hash_str(const char *str)
|
|
{
|
|
return siphash24(siphash_seed(), str, strlen(str));
|
|
}
|
|
|
|
#endif /* LIGHTNING_COMMON_HASH_STR_H */
|