From fa402aac31083d54bf494011ee6cc3b1fd94a78d 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 6c1c60730..be011d1f1 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)