]> the.earth.li Git - onak.git/commitdiff
Remove dead store in generic_fetch_key
authorJonathan McDowell <noodles@earth.li>
Sat, 2 Jan 2021 11:05:46 +0000 (11:05 +0000)
committerJonathan McDowell <noodles@earth.li>
Sat, 2 Jan 2021 11:05:46 +0000 (11:05 +0000)
We don't use curkey once we've found the key, so there's no need to set
it here.

keydb/keydb.c

index 692a7b7c902a42590b92d5ec29cbdc01e409e714..20f07d26d9528b91ef4480073315ad4444c84d5e 100644 (file)
@@ -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;