From 743957a08f068529d3add3e8485678b4e5034195 Mon Sep 17 00:00:00 2001 From: Jonathan McDowell Date: Sat, 2 Jan 2021 11:05:46 +0000 Subject: [PATCH] Remove dead store in generic_fetch_key We don't use curkey once we've found the key, so there's no need to set it here. --- keydb/keydb.c | 1 - 1 file changed, 1 deletion(-) diff --git a/keydb/keydb.c b/keydb/keydb.c index 692a7b7..20f07d2 100644 --- a/keydb/keydb.c +++ b/keydb/keydb.c @@ -315,7 +315,6 @@ static int generic_fetch_key(struct onak_dbctx *dbctx, if (get_fingerprint(curkey->publickey, &fp) == ONAK_E_OK) { if (fingerprint_cmp(fingerprint, &fp) == 0) { *newkey = curkey; - curkey = curkey->next; (*newkey)->next = NULL; count = 1; break; -- 2.39.5