aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorWerner Koch <[email protected]>2021-05-28 16:31:26 +0000
committerWerner Koch <[email protected]>2021-05-28 16:31:43 +0000
commit31eb45f01620d3e8811fe18460c281837bb3359f (patch)
tree0bf377ae32fe8347d21e4e57c86876b9582ca34d
parentbuild: _DARWIN_C_SOURCE should be 1. (diff)
downloadgpgme-31eb45f01620d3e8811fe18460c281837bb3359f.tar.gz
gpgme-31eb45f01620d3e8811fe18460c281837bb3359f.zip
tests: Improve the output of the run-keylist helper.
* tests/run-keylist.c (main): Print all infos from the primary key. -- The test tool printed only the computed infos for the key and not the detailed one fro the primary key. The new output better reflects the data structure. Related to GnuPG-bug-id: 5454
-rw-r--r--tests/run-keylist.c9
1 files changed, 1 insertions, 8 deletions
diff --git a/tests/run-keylist.c b/tests/run-keylist.c
index f0ab74e8..27cdbb2a 100644
--- a/tests/run-keylist.c
+++ b/tests/run-keylist.c
@@ -272,11 +272,6 @@ main (int argc, char **argv)
int nsigs;
printf ("keyid : %s\n", key->subkeys?nonnull (key->subkeys->keyid):"?");
- printf ("fpr : %s\n", key->subkeys?nonnull (key->subkeys->fpr):"?");
- if (key->subkeys && key->subkeys->keygrip)
- printf ("grip : %s\n", key->subkeys->keygrip);
- if (key->subkeys && key->subkeys->curve)
- printf ("curve : %s\n", key->subkeys->curve);
printf ("caps : %s%s%s%s\n",
key->can_encrypt? "e":"",
key->can_sign? "s":"",
@@ -294,9 +289,7 @@ main (int argc, char **argv)
printf ("upd : %lu (%u)\n", key->last_update, key->origin);
subkey = key->subkeys;
- if (subkey)
- subkey = subkey->next;
- for (nsub=1; subkey; subkey = subkey->next, nsub++)
+ for (nsub=0; subkey; subkey = subkey->next, nsub++)
{
printf ("fpr %2d: %s\n", nsub, nonnull (subkey->fpr));
if (subkey->keygrip)