From: Jonathan McDowell Date: Tue, 19 Nov 2013 05:44:46 +0000 (-0800) Subject: Another deletion fix of 64 bit keys in DB4 backend X-Git-Tag: onak-0.4.3~22 X-Git-Url: http://the.earth.li/gitweb/?p=onak.git;a=commitdiff_plain;h=1a5992e47f6e1bfc4bd2faee14947b3f218a3e46 Another deletion fix of 64 bit keys in DB4 backend We weren't deleting the actual key data when a key had been correctly stored using its fingerprint. --- diff --git a/keydb_db4.c b/keydb_db4.c index 20a12fd..43f1674 100644 --- a/keydb_db4.c +++ b/keydb_db4.c @@ -1124,6 +1124,16 @@ static int db4_delete_key(struct onak_dbctx *dbctx, publickey = NULL; if (!deadlock) { + key.data = fingerprint.fp; + key.size = fingerprint.length; + + keydb_fp(privctx, &fingerprint)->del(keydb_fp(privctx, + &fingerprint), + privctx->txn, + &key, + 0); /* flags */ + + /* Delete old style 64 bit keyid */ key.data = &keyid; key.size = sizeof(keyid);