From 5349d2aaa7657d64b3fe63eefaf41c3be6af2767 Mon Sep 17 00:00:00 2001 From: Rusty Russell Date: Tue, 1 Nov 2016 21:33:06 +1030 Subject: [PATCH] routing: fix hash of pubkeys. Found by PVS Studio. Reported-by: Jon Griffiths Signed-off-by: Rusty Russell --- daemon/routing.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/daemon/routing.c b/daemon/routing.c index 0b42f9039..4e8f72783 100644 --- a/daemon/routing.c +++ b/daemon/routing.c @@ -21,7 +21,7 @@ static const secp256k1_pubkey *keyof_node(const struct node *n) static size_t hash_key(const secp256k1_pubkey *key) { - return siphash24(siphash_seed(), key, sizeof(key)); + return siphash24(siphash_seed(), key, sizeof(*key)); } static bool node_eq(const struct node *n, const secp256k1_pubkey *key)