]> the.earth.li Git - onak.git/blobdiff - keydb_fs.c
Add support for displaying EC/ECDSA key types
[onak.git] / keydb_fs.c
index ea09c7c0dae882e0684f3174c35397e26fccadaa..b7117bebab4ffeda8f4bf36a2b650eb3c600a256 100644 (file)
@@ -329,13 +329,17 @@ static int fs_store_key(struct openpgp_publickey *publickey, bool intrans,
        struct openpgp_packet_list *packets = NULL;
        struct openpgp_packet_list *list_end = NULL;
        struct openpgp_publickey *next = NULL;
-       uint64_t keyid = get_keyid(publickey);
+       uint64_t keyid;
        struct ll *wordlist = NULL, *wl = NULL;
        struct skshash hash;
        uint64_t *subkeyids = NULL;
        uint32_t hashid;
        int i = 0;
 
+       if (get_keyid(publickey, &keyid) != ONAK_E_OK) {
+               logthing(LOGTHING_ERROR, "Couldn't find key ID for key.");
+               return 0;
+       }
 
        if (!intrans)
                fs_starttrans();